1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 13:37:25 +08:00

Make resolved multiplayerClient field nullable

This commit is contained in:
Marvin Schürz 2023-10-04 08:35:45 +02:00
parent 0726ccb988
commit 6bd51b32b4

View File

@ -64,7 +64,7 @@ namespace osu.Game.Users
protected OsuColour Colours { get; private set; } = null!;
[Resolved]
private MultiplayerClient multiplayerClient { get; set; } = null!;
private MultiplayerClient? multiplayerClient { get; set; }
[BackgroundDependencyLoader]
private void load()
@ -124,7 +124,7 @@ namespace osu.Game.Users
if (
User.IsOnline &&
multiplayerClient.Room != null &&
multiplayerClient?.Room != null &&
multiplayerClient.Room.Users.All(u => u.UserID != User.Id)
)
{