diff --git a/src/LipUI/Global.cs b/src/LipUI/Global.cs index b2f20b2..3cccf4e 100644 --- a/src/LipUI/Global.cs +++ b/src/LipUI/Global.cs @@ -379,7 +379,7 @@ void Save() { Directory.CreateDirectory(dir); } - File.WriteAllText(fp, result.ToString()); + File.WriteAllText(fp, result?.ToString()); } catch { diff --git a/src/LipUI/ViewModels/InstallPageViewModel.cs b/src/LipUI/ViewModels/InstallPageViewModel.cs index a0d6471..ead3f38 100644 --- a/src/LipUI/ViewModels/InstallPageViewModel.cs +++ b/src/LipUI/ViewModels/InstallPageViewModel.cs @@ -193,7 +193,7 @@ public async Task FetchInfo() }); if (success) { - if (ToothInfoPanel.Tooth != ToothName) + if (ToothInfoPanel?.Tooth != ToothName) { ToothInfoPanel = new ToothInfoPanelViewModel(package!) {