Skip to content

Instantly share code, notes, and snippets.

@percybolmer
Created July 30, 2021 05:29
Show Gist options
  • Save percybolmer/0c403025b59bd71fe4a5fea1f426ab59 to your computer and use it in GitHub Desktop.
Save percybolmer/0c403025b59bd71fe4a5fea1f426ab59 to your computer and use it in GitHub Desktop.
/**
* @notice
* A stake struct is used to represent the way we store stakes,
* A Stake will contain the users address, the amount staked and a timestamp,
* Since which is when the stake was made
*/
struct Stake{
address user;
uint256 amount;
uint256 since;
// This claimable field is new and used to tell how big of a reward is currently available
uint256 claimable;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment