Refactor SkinnableSound.Samples to be non-nullable

This commit is contained in:
Dean Herbert
2023-01-27 19:32:30 +09:00
parent 8a9a6c733c
commit 74ab036f3e
5 changed files with 7 additions and 8 deletions

View File

@ -303,8 +303,7 @@ namespace osu.Game.Rulesets.Objects.Drawables
samplesBindable.CollectionChanged -= onSamplesChanged;
// Release the samples for other hitobjects to use.
if (Samples != null)
Samples.Samples = null;
Samples?.ClearSamples();
foreach (var obj in nestedHitObjects)
{