Skip to content

Commit b82b914

Browse files
authored
Fixed a crash when opening the conflicts dialog (#8005)
1 parent 836a492 commit b82b914

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/Files/Dialogs/FilesystemOperationDialog.xaml.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,10 @@ protected override void OnApplyTemplate()
4242
private void PrimaryButton_GotFocus(object sender, RoutedEventArgs e)
4343
{
4444
(sender as Button).GotFocus -= PrimaryButton_GotFocus;
45-
chkPermanentlyDelete.IsEnabled = ViewModel.PermanentlyDeleteEnabled;
45+
if (chkPermanentlyDelete != null)
46+
{
47+
chkPermanentlyDelete.IsEnabled = ViewModel.PermanentlyDeleteEnabled;
48+
}
4649
DetailsGrid.IsEnabled = true;
4750
}
4851

0 commit comments

Comments
 (0)