1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-06 06:57:39 +08:00

Remove redundant type specs

This commit is contained in:
Bartłomiej Dach 2022-12-26 23:12:53 +01:00
parent 335cb0205f
commit cb2b0d4178
No known key found for this signature in database
2 changed files with 2 additions and 2 deletions

View File

@ -344,7 +344,7 @@ namespace osu.Game.Beatmaps.Formats
private AnimationLoopType parseAnimationLoopType(string value)
{
var parsed = Enum.Parse<AnimationLoopType>(value);
return Enum.IsDefined<AnimationLoopType>(parsed) ? parsed : AnimationLoopType.LoopForever;
return Enum.IsDefined(parsed) ? parsed : AnimationLoopType.LoopForever;
}
private void handleVariables(string line)

View File

@ -185,7 +185,7 @@ namespace osu.Game.Online.API.Requests.Responses
[JsonProperty(@"playstyle")]
private string[] playStyle
{
set => PlayStyles = value?.Select(str => Enum.Parse<APIPlayStyle>(str, true)).Cast<APIPlayStyle>().ToArray();
set => PlayStyles = value?.Select(str => Enum.Parse<APIPlayStyle>(str, true)).ToArray();
}
public APIPlayStyle[] PlayStyles;