Skip to content

Commit

Permalink
Improved: Startup time via Async Envrionment Variable Change
Browse files Browse the repository at this point in the history
  • Loading branch information
Sewer56 committed Feb 5, 2022
1 parent e287d22 commit 4f17f31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/Reloaded.Mod.Launcher.Lib/Setup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public static async Task SetupApplicationAsync(Action<string> updateText, int mi
UpdateDefaultConfig(); // Fire and forget.
#pragma warning restore 4014
CheckForMissingDependencies();

updateText(Resources.SplashPreparingResources.Get());
await Task.Run(SetupServices);
SetupViewModels();
Expand Down Expand Up @@ -297,7 +297,7 @@ private static void SetLoaderPaths(LoaderConfig config, string launcherDirectory
config.Bootstrapper64Path = bootstrapper64Path;

// Update Environment Variables
Environment.SetEnvironmentVariable("RELOADEDIIMODS", config.ModConfigDirectory, EnvironmentVariableTarget.User);
Task.Run(() => Environment.SetEnvironmentVariable("RELOADEDIIMODS", config.ModConfigDirectory, EnvironmentVariableTarget.User));
}

/// <summary>
Expand Down

0 comments on commit 4f17f31

Please sign in to comment.