From 3630ab2db2da2ee6b0291bf0e3cedfd47a8f020f Mon Sep 17 00:00:00 2001 From: Salman Ahmed Date: Thu, 3 Mar 2022 00:09:12 +0300 Subject: [PATCH] Remove unnecessary nullability of storyboard mods list --- osu.Game/Storyboards/Drawables/DrawableStoryboard.cs | 3 +-- osu.Game/Storyboards/Storyboard.cs | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/osu.Game/Storyboards/Drawables/DrawableStoryboard.cs b/osu.Game/Storyboards/Drawables/DrawableStoryboard.cs index 840500347f..01e4dfca02 100644 --- a/osu.Game/Storyboards/Drawables/DrawableStoryboard.cs +++ b/osu.Game/Storyboards/Drawables/DrawableStoryboard.cs @@ -1,7 +1,6 @@ // Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. // See the LICENCE file in the repository root for full licence text. -using System; using System.Collections.Generic; using System.Linq; using System.Threading; @@ -64,7 +63,7 @@ namespace osu.Game.Storyboards.Drawables public DrawableStoryboard(Storyboard storyboard, IReadOnlyList mods) { Storyboard = storyboard; - Mods = mods ?? Array.Empty(); + Mods = mods; Size = new Vector2(640, 480); diff --git a/osu.Game/Storyboards/Storyboard.cs b/osu.Game/Storyboards/Storyboard.cs index 2faed98ae0..844950336d 100644 --- a/osu.Game/Storyboards/Storyboard.cs +++ b/osu.Game/Storyboards/Storyboard.cs @@ -91,7 +91,7 @@ namespace osu.Game.Storyboards } } - public DrawableStoryboard CreateDrawable(IReadOnlyList mods = null) => + public DrawableStoryboard CreateDrawable(IReadOnlyList mods) => new DrawableStoryboard(this, mods); public Drawable CreateSpriteFromResourcePath(string path, TextureStore textureStore)