Sidebar - Fix importing

This commit is contained in:
Robert committed 2022-08-20 10:42:56 +02:00
1 parent 4722aa413b
commit 3257f94548
1 file changed
+13 -6
@@ -165,12 +165,19 @@ namespace Artemis.UI.Screens.Sidebar
return; return;
} }
// Remove the temporary profile configuration try
_profileService.RemoveProfileConfiguration(_profileConfiguration); {
// Import the new profile configuration ProfileConfiguration profileConfiguration = _profileService.ImportProfile(_profileCategory, profileConfigurationExportModel);
_profileService.ImportProfile(_profileCategory, profileConfigurationExportModel);
// Remove the temporary profile configuration
Close(_profileConfiguration); _profileService.RemoveProfileConfiguration(_profileConfiguration);
Close(profileConfiguration);
}
catch (Exception e)
{
_windowService.ShowExceptionDialog("Import profile failed", e);
}
} }
private async Task ExecuteDelete() private async Task ExecuteDelete()