Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sidechain distribution contract #2

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

pumpurum2
Copy link
Collaborator

No description provided.

contracts/veDistributionSnapshot.sol Outdated Show resolved Hide resolved
contracts/veDistributionSnapshot.sol Show resolved Hide resolved
contracts/veDistributionSnapshot.sol Outdated Show resolved Hide resolved
@pumpurum2
Copy link
Collaborator Author

pumpurum2 commented Sep 26, 2022

@Eenae fixed, added deploy script and new method for checking available reward (sorry, didn't think about it right away)

function withdrawReward(IERC20[] calldata tokens_) public {
function availableReward(address user_, IERC20 token_) public view returns (uint) {
uint userBalance = balanceOf[user_];
if (userBalance == 0) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps, zero should be returned also during the snapshot population, since rewards may jump misleadingly during that process.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants