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
Feat: Statistics rewards #1129
Feat: Statistics rewards #1129
Conversation
helpers/github.ts
Outdated
|
||
// Increment rewards statistics, if it is assigned but not completed | ||
if (isAssigned && !isCompleted) { | ||
rewards.assigned += price; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this have proper error handling for NaN etc?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added an error handling now, although i had a check for price not set earlier but NaN check would make it better
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good. Would like to see a successful test run, and its results.
Resolves ubiquity/devpool-directory-bounties#19
Test Run: https://github.com/devpanther/devpool-directory/blob/development/total-rewards.json