From f934b059c8f53d73f6f8bbc3e528512d9782ae5e Mon Sep 17 00:00:00 2001 From: adelikat Date: Fri, 20 Dec 2019 10:24:54 -0600 Subject: [PATCH] fix a few potential NRE's in Global.cs --- BizHawk.Client.Common/Global.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/BizHawk.Client.Common/Global.cs b/BizHawk.Client.Common/Global.cs index a2c9fc04a3..aaa2849701 100644 --- a/BizHawk.Client.Common/Global.cs +++ b/BizHawk.Client.Common/Global.cs @@ -26,7 +26,7 @@ namespace BizHawk.Client.Common /// public static int SoundMaxBufferDeficitMs; - // the movie will be spliced inbetween these if it is present + // the movie will be spliced in between these if it is present public static readonly CopyControllerAdapter MovieInputSourceAdapter = new CopyControllerAdapter(); public static readonly CopyControllerAdapter MovieOutputHardpoint = new CopyControllerAdapter(); public static readonly MultitrackRewiringControllerAdapter MultitrackRewiringAdapter = new MultitrackRewiringControllerAdapter(); @@ -86,12 +86,12 @@ namespace BizHawk.Client.Common case "SG": return SystemInfo.SG; case "SMS": - if ((Emulator as SMS).IsGameGear) + if (Emulator is SMS gg && gg.IsGameGear) { return SystemInfo.GG; } - if ((Emulator as SMS).IsSG1000) + if (Emulator is SMS sg && sg.IsSG1000) { return SystemInfo.SG; }