1
0
mirror of https://github.com/ppy/osu.git synced 2025-03-17 22:17:25 +08:00

Guard against empty values early

This commit is contained in:
Bartłomiej Dach 2020-11-23 21:24:37 +01:00
parent e9ffeb8b5d
commit bb5aa9a9c9

View File

@ -26,8 +26,10 @@ namespace osu.Game.Overlays.Profile.Sections.Historical
get => values;
set
{
values = value;
graph.Values = values;
if (value.Length == 0)
throw new ArgumentException("At least one value expected!", nameof(value));
graph.Values = values = value;
createRowTicks();
createColumnTicks();