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:
parent
335cb0205f
commit
cb2b0d4178
@ -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)
|
||||
|
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user