Closed ctm closed 2 weeks ago
I chose not to hoist the code. Instead, I replicated the semantics, because it makes more sense to fix "properly" more things than just this, but this should be fixed sooner rather than later, because currently incorrect info is being produced.
It's such a small fix, I've put it in master, but I'm not deploying until later today when I'll have done more work on various small issues (#1445).
Fix so that if N Players Auotstart is chosen during event creation, Start At doesn't show up in the tentative structure sheet.
I should have checked this before deploying, but I thought we do a faithful reproduction of what is in
NewEvent
so I didn't anticipate it. The problem is that we have some additional rules that we apply inmodels::EventRow::create
, one being:That was fine when the user could only see the creation modal before creating, because by the time the user could see anything else, that code was hit.
The solution is to hoist all similar code out of
NewEvent::create
and into something that is called by both the code that callsNewEvent::create
and is also called byStructureSheetDetails::tournament
. It does not make sense to do the n-players-autostart xor create-at hack in the creation modal UI, because we currently keep the create-at just in case a value in n-players-autostart was an error and the user erases it.