Add referral bonus during grading - #235
Conversation
crystaltine
left a comment
There was a problem hiding this comment.
Kinda works, but it only applies the bonus when the last essay is graded, so if someone is referred after their essays have already been graded, the bonus never gets checked, i think.
I think maybe it would be better to just store a separate referral bonus field and do the sum when we rank grading rather than bumping the raw score?
OR maybe we can just have the referral routes also update the application score and then make sure neither route that touches the application score overwrites it (+= instead)
There was a problem hiding this comment.
Thanks for the fix!
One small edge case could be if a grade and a referral somehow get submitted at the same time and each one updates the score on its own
- however this would probably just lead to the bonus getting counted twice, which isnt really breaking
Also i think it still is better overall to have a separate field for this, but then we have to handle the cases of creating a referral before an application starts and patching all the usages of essay scores to also account for the referralBonus field, so we can probably leave that to a future improvement for now.
Improvement issue: #236 (comment)
Description
Issues