diff --git a/Wabbajack/App.xaml.cs b/Wabbajack/App.xaml.cs index bf222817..982bc815 100644 --- a/Wabbajack/App.xaml.cs +++ b/Wabbajack/App.xaml.cs @@ -1,4 +1,5 @@ using System; +using System.Reflection; using System.Windows; using Wabbajack.Common; using Wabbajack.Lib.Updater; @@ -29,6 +30,12 @@ namespace Wabbajack Environment.Exit(1); }*/ + var appPath = Assembly.GetExecutingAssembly().Location; + if (!(ExtensionManager.IsAssociated(appPath) || ExtensionManager.NeedsUpdating(appPath))) + { + ExtensionManager.Associate(appPath); + } + string[] args = Environment.GetCommandLineArgs(); StartupUri = new Uri("UI/ModeSelectionWindow.xaml", UriKind.Relative); if (args.Length != 3) return; diff --git a/Wabbajack/AppState.cs b/Wabbajack/AppState.cs index fcc8f9ba..9eea5bb0 100644 --- a/Wabbajack/AppState.cs +++ b/Wabbajack/AppState.cs @@ -85,12 +85,6 @@ namespace Wabbajack Environment.Exit(1); } - var appPath = Assembly.GetExecutingAssembly().Location; - if (!(ExtensionManager.IsAssociated(appPath) || ExtensionManager.NeedsUpdating(appPath))) - { - ExtensionManager.Associate(appPath); - } - Mode = mode; // Define commands