Merge if statements

This commit is contained in:
Dean Herbert 2020-03-30 18:56:35 +09:00
parent ec18fe1f9f
commit 113660b621

View File

@ -89,22 +89,19 @@ namespace osu.Game.Screens.Ranking
} }
}; };
if (player != null) if (player != null && allowRetry)
{ {
if (allowRetry) buttons.Add(new RetryButton { Width = 300 });
AddInternal(new HotkeyRetryOverlay
{ {
buttons.Add(new RetryButton { Width = 300 }); Action = () =>
AddInternal(new HotkeyRetryOverlay
{ {
Action = () => if (!this.IsCurrentScreen()) return;
{
if (!this.IsCurrentScreen()) return;
player?.Restart(); player?.Restart();
}, },
}); });
}
} }
} }