瀏覽代碼

Ava: Add missing null check to ContentDialogHelper.ShowAsync() (#4248)

* ava: Add missing null check to ContentDialogHelper.ShowAsync()

* Replace "is not" with != operator

Co-authored-by: gdkchan <gab.dark.100@gmail.com>

Co-authored-by: gdkchan <gab.dark.100@gmail.com>
TSRBerry 3 年之前
父節點
當前提交
3e455a90a1
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Ryujinx.Ava/UI/Helpers/ContentDialogHelper.cs

+ 1 - 1
Ryujinx.Ava/UI/Helpers/ContentDialogHelper.cs

@@ -349,7 +349,7 @@ namespace Ryujinx.Ava.UI.Helpers
 
             Window parent = GetMainWindow();
 
-            if (parent.IsActive && parent is MainWindow window && window.ViewModel.IsGameRunning)
+            if (parent != null && parent.IsActive && parent is MainWindow window && window.ViewModel.IsGameRunning)
             {
                 contentDialogOverlayWindow = new()
                 {