Closed morckx closed 6 years ago
Ohai, yeah that was un-good. Thanks for the hint, I was wondering what was causing this.
There’s this equality check which should only update the competition when there are changes. The if
evaluated to true
because Competition#lastUpdated
differed. It then saved the competition which was derived from the DTO here and that has its Competiton#current
set to false
since that is the default.
I’m going to provide a fix later this evening.
Yes, exactly :) That's what I just have found out, too. Thanks.
FYI, Competition#championBetAllowed
was also reset to true
.
Thanks for the hint! I noticed it, but at that time wasn't sure if was erroneously reset or wasn't set to false in the first place.
… probably in updateCurrentCompetitionWithItsTeams cron job so that the current competition becomes unavailable.
Maybe it should be checked here:
https://github.com/Zemke/tippspiel2/blob/master/tippspiel2-spring/src/main/kotlin/com/github/zemke/tippspiel2/service/CompetitionService.kt#L28
also if the currentCurrentCompetition is not the same as the currentCompetition?