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

haloHaloAmount should be renamed to haloAmount #3

Closed
cleanunicorn opened this issue Jun 29, 2021 · 0 comments
Closed

haloHaloAmount should be renamed to haloAmount #3

cleanunicorn opened this issue Jun 29, 2021 · 0 comments

Comments

@cleanunicorn
Copy link
Member

Description

When a user wants to unstake their tokens, they need to call leave.

https://github.com/monoceros-alpha/review-halodao-rewards-2021-06/blob/625eb4d3d0f780cfe06bb3f44ccbbea37149bd8b/code/contracts/HaloHalo.sol#L44-L46

The amount of tokens to be unlocked is calculated and saved in a local variable haloHaloAmount:

https://github.com/monoceros-alpha/review-halodao-rewards-2021-06/blob/625eb4d3d0f780cfe06bb3f44ccbbea37149bd8b/code/contracts/HaloHalo.sol#L49-L51

This value should be named haloAmount because this value is then used to send the halo tokens back to the user.

https://github.com/monoceros-alpha/review-halodao-rewards-2021-06/blob/625eb4d3d0f780cfe06bb3f44ccbbea37149bd8b/code/contracts/HaloHalo.sol#L53

Recommendation

Rename the variable haloHaloAmount to haloAmount.

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

No branches or pull requests

1 participant