Skip to content

Instantly share code, notes, and snippets.

@skmgoldin
Created November 12, 2017 20:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save skmgoldin/44e2a37880a487d7aeab7fe333479a07 to your computer and use it in GitHub Desktop.
Save skmgoldin/44e2a37880a487d7aeab7fe333479a07 to your computer and use it in GitHub Desktop.
function voterReward(Data storage _self, address _voter, uint _salt)
public constant returns (uint) {
uint voterTokens = _self.voting.getNumPassingTokens(_voter, _self.challengeID, _salt);
return (voterTokens * _self.rewardPool) / _self.winningTokens;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment