mirror of
https://github.com/ppy/osu.git
synced 2024-11-06 06:57:39 +08:00
Automatically fix invalid pairing dates on load (based on contained groupings)
This commit is contained in:
parent
f083b18663
commit
8907ce3f63
@ -109,7 +109,12 @@ namespace osu.Game.Tournament
|
||||
foreach (var id in group.Pairings)
|
||||
{
|
||||
var found = Ladder.Pairings.FirstOrDefault(p => p.ID == id);
|
||||
if (found != null) found.Grouping.Value = group;
|
||||
if (found != null)
|
||||
{
|
||||
found.Grouping.Value = group;
|
||||
if (group.StartDate.Value > found.Date.Value)
|
||||
found.Date.Value = group.StartDate.Value;
|
||||
}
|
||||
}
|
||||
|
||||
Ladder.CurrentMatch.Value = Ladder.Pairings.FirstOrDefault(p => p.Current.Value);
|
||||
|
Loading…
Reference in New Issue
Block a user