mirror of
https://github.com/ppy/osu.git
synced 2025-03-23 16:27:20 +08:00
Return empty strings rather than erroring
Preventing malicious actors from permanently destroying games via skins.
This commit is contained in:
parent
2de5e3392e
commit
e27aa0c761
@ -132,7 +132,7 @@ namespace osu.Game.Skinning.Components
|
||||
return BeatmapsetsStrings.ShowStatsBpm;
|
||||
|
||||
default:
|
||||
throw new ArgumentOutOfRangeException(nameof(attribute), attribute, $@"Unrecognised {nameof(BeatmapAttribute)}");
|
||||
return string.Empty;
|
||||
}
|
||||
}
|
||||
|
||||
@ -180,7 +180,7 @@ namespace osu.Game.Skinning.Components
|
||||
return beatmap.Value.BeatmapInfo.StarRating.ToLocalisableString(@"F2");
|
||||
|
||||
default:
|
||||
throw new ArgumentOutOfRangeException(nameof(attribute), attribute, $@"Unrecognised {nameof(BeatmapAttribute)}");
|
||||
return string.Empty;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user