Closed trouni closed 3 months ago
I'm wondering if we should be validating it on the status or the actual kickoff time. Because we're reliant on the API to update the status, whereas we already know if a game as started technically.
@dmbf29 I think it would be reasonable to add a check on the time as well 👍
Scope of this PR
This PR creates a new
editable
scope for predictions and uses it in thepredictions#update
action to prevent editing predictions on matches that are already started or finished.Didn't look into error handling, just protecting this for now as it should definitely be prevented.
Notes
We should really add RSpec 😓