Browse Source

Null check

flabbet 3 years ago
parent
commit
3104bf3302
1 changed files with 1 additions and 1 deletions
  1. 1 1
      PixiEditor/Models/DataHolders/Document/Document.cs

+ 1 - 1
PixiEditor/Models/DataHolders/Document/Document.cs

@@ -207,7 +207,7 @@ namespace PixiEditor.Models.DataHolders
 
         private void SetAsActiveOnClick(object obj)
         {
-            if (XamlAccesibleViewModel.BitmapManager.ActiveDocument != this)
+            if (XamlAccesibleViewModel?.BitmapManager?.ActiveDocument != this)
             {
                 XamlAccesibleViewModel.BitmapManager.ActiveDocument = this;
             }