diff --git a/OpenSky.Agent/App.xaml.cs b/OpenSky.Agent/App.xaml.cs index 97ffc8b..8f6b66c 100644 --- a/OpenSky.Agent/App.xaml.cs +++ b/OpenSky.Agent/App.xaml.cs @@ -305,9 +305,15 @@ private static void AppDispatcherUnhandledException( try { + var openSkyFolder = Environment.ExpandEnvironmentVariables("%localappdata%\\OpenSky"); + if (!Directory.Exists(openSkyFolder)) + { + Directory.CreateDirectory(openSkyFolder); + } + File.AppendAllText(filePath, crashReport); ModernWpf.MessageBox.Show( - e.Exception.Message + "\r\n\r\nPlease check agent_crash.log for details!", + $"{e.Exception.Message}\r\n\r\nPlease check {filePath} for details!", "Unexpected error!", MessageBoxButton.OK, MessageBoxImage.Error); diff --git a/OpenSky.Agent/Properties/AssemblyInfo.cs b/OpenSky.Agent/Properties/AssemblyInfo.cs index c4e0140..ccc5344 100644 --- a/OpenSky.Agent/Properties/AssemblyInfo.cs +++ b/OpenSky.Agent/Properties/AssemblyInfo.cs @@ -21,8 +21,8 @@ [assembly: AssemblyCulture("")] [assembly: ComVisible(false)] [assembly: ThemeInfo(ResourceDictionaryLocation.None, ResourceDictionaryLocation.SourceAssembly)] -[assembly: AssemblyVersion("0.5.0")] -[assembly: AssemblyFileVersion("0.5.0")] +[assembly: AssemblyVersion("0.5.1")] +[assembly: AssemblyFileVersion("0.5.1")] // This allows us to detect debug mode in XAML #if DEBUG diff --git a/OpenSky.Agent/Views/Models/AircraftTypesViewModel.cs b/OpenSky.Agent/Views/Models/AircraftTypesViewModel.cs index 06f8003..e29013f 100644 --- a/OpenSky.Agent/Views/Models/AircraftTypesViewModel.cs +++ b/OpenSky.Agent/Views/Models/AircraftTypesViewModel.cs @@ -1906,8 +1906,11 @@ private void GetUserRoles() var result = UserSessionService.Instance.UpdateUserRoles().Result; if (result) { - this.GetUserRolesCommand.ReportProgress(() => this.RefreshAircraftTypesCommand.DoExecute(null)); - this.GetAircraftUpgradesCommand.CanExecute = UserSessionService.Instance.IsModerator; + this.GetUserRolesCommand.ReportProgress(() => + { + this.RefreshAircraftTypesCommand.DoExecute(null); + this.GetAircraftUpgradesCommand.CanExecute = UserSessionService.Instance.IsModerator; + }); } else { diff --git a/changelog.txt b/changelog.txt index 19b7cf7..f1daef4 100644 --- a/changelog.txt +++ b/changelog.txt @@ -2,6 +2,11 @@ OpenSky Flight Tracking Agent Changelog ====================================================================================== +-------------------------------------------------------------------------------------- +Version 0.5.1 (ALPHA5) +-------------------------------------------------------------------------------------- +- Fixed crash in aircraft type editor + -------------------------------------------------------------------------------------- Version 0.5.0 (ALPHA5) --------------------------------------------------------------------------------------