From 9d8141475f211f24130ec132019372866813881a Mon Sep 17 00:00:00 2001 From: Garry Newman Date: Tue, 8 Nov 2016 10:14:10 +0000 Subject: [PATCH] Fixed NRE in request --- Facepunch.Steamworks/Client/ServerList.Request.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Facepunch.Steamworks/Client/ServerList.Request.cs b/Facepunch.Steamworks/Client/ServerList.Request.cs index f6086d9..daefb6a 100644 --- a/Facepunch.Steamworks/Client/ServerList.Request.cs +++ b/Facepunch.Steamworks/Client/ServerList.Request.cs @@ -195,7 +195,8 @@ namespace Facepunch.Steamworks /// public void Dispose() { - client.OnUpdate -= Update; + if ( client.IsValid ) + client.OnUpdate -= Update; // // Cancel the query if it's still running