From c2ef38e378e83c89906f7c467efab4bfae963905 Mon Sep 17 00:00:00 2001 From: Blake Pell Date: Wed, 17 Aug 2022 19:28:46 -0400 Subject: [PATCH] Weird network crash fix in MSIX deployment. --- src/Avalon.Client/HashCommands/Beep.cs | 4 ++-- src/Avalon.Client/MainWindow.Network.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Avalon.Client/HashCommands/Beep.cs b/src/Avalon.Client/HashCommands/Beep.cs index c681760d..b9e0e5c2 100644 --- a/src/Avalon.Client/HashCommands/Beep.cs +++ b/src/Avalon.Client/HashCommands/Beep.cs @@ -65,11 +65,11 @@ public override void Execute() return; } - App.Beep.Play(); + App.Beep?.Play(); return; default: - SystemSounds.Beep.Play(); + SystemSounds.Beep?.Play(); return; } }); diff --git a/src/Avalon.Client/MainWindow.Network.cs b/src/Avalon.Client/MainWindow.Network.cs index 8328411f..8c51d3d3 100644 --- a/src/Avalon.Client/MainWindow.Network.cs +++ b/src/Avalon.Client/MainWindow.Network.cs @@ -139,7 +139,7 @@ public void HandleLineReceived(object sender, string e) // One beep per line max, everything else is ignored. if (App.Settings.ProfileSettings.AnsiBeep && e.Contains('\a')) { - App.Beep.Play(); + App.Beep?.Play(); } try