From 97f9170ed55c364fe7899857ad8cfc29054978cf Mon Sep 17 00:00:00 2001 From: Beyley Thomas Date: Sat, 2 Sep 2023 00:04:15 -0700 Subject: [PATCH] Check for null NatType in find room match --- .../Types/Matching/MatchMethods/FindRoomMethod.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Refresh.GameServer/Types/Matching/MatchMethods/FindRoomMethod.cs b/Refresh.GameServer/Types/Matching/MatchMethods/FindRoomMethod.cs index 7dd18d62..ab01af8d 100644 --- a/Refresh.GameServer/Types/Matching/MatchMethods/FindRoomMethod.cs +++ b/Refresh.GameServer/Types/Matching/MatchMethods/FindRoomMethod.cs @@ -44,7 +44,7 @@ public Response Execute(MatchService service, LoggerContainer log .ToList(); //When a user is behind a Strict NAT layer, we can only connect them to players with Open NAT types - if (body.NatType[0] == NatType.Strict) + if (body.NatType != null && body.NatType[0] == NatType.Strict) { rooms = rooms.Where(r => r.NatType == NatType.Open).ToList(); }