mirror of
https://github.com/ppy/osu.git
synced 2025-01-13 07:22:54 +08:00
Remove unnecesasry null check on content
This commit is contained in:
parent
18700b4daa
commit
ec12186d63
@ -74,17 +74,12 @@ namespace osu.Game.Skinning
|
||||
cancellationSource?.Cancel();
|
||||
cancellationSource = null;
|
||||
|
||||
if (content != null)
|
||||
LoadComponentAsync(content, wrapper =>
|
||||
{
|
||||
LoadComponentAsync(content, wrapper =>
|
||||
{
|
||||
AddInternal(wrapper);
|
||||
components.AddRange(wrapper.Children.OfType<ISerialisableDrawable>());
|
||||
ComponentsLoaded = true;
|
||||
}, (cancellationSource = new CancellationTokenSource()).Token);
|
||||
}
|
||||
else
|
||||
AddInternal(wrapper);
|
||||
components.AddRange(wrapper.Children.OfType<ISerialisableDrawable>());
|
||||
ComponentsLoaded = true;
|
||||
}, (cancellationSource = new CancellationTokenSource()).Token);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ISerialisableDrawableContainer"/>
|
||||
|
Loading…
Reference in New Issue
Block a user