Skip to content

Commit 76601e4

Browse files
committed
Fixed get exePath for single file deploy
1 parent 7a4adf6 commit 76601e4

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

UWPHook/GamesWindow.xaml.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -384,8 +384,9 @@ private async Task<bool> ExportGames()
384384
{
385385
var users = SteamManager.GetUsers(steam_folder);
386386
var selected_apps = Apps.Entries.Where(app => app.Selected);
387-
var exePath = @"""" + System.Reflection.Assembly.GetExecutingAssembly().Location + @"""";
388-
var exeDir = Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location);
387+
var processModule = Process.GetCurrentProcess().MainModule;
388+
var exePath = processModule?.FileName;
389+
var exeDir = Path.GetDirectoryName(exePath);
389390

390391
List<Task> gridImagesDownloadTasks = new List<Task>();
391392
bool downloadGridImages = !String.IsNullOrEmpty(Properties.Settings.Default.SteamGridDbApiKey);

0 commit comments

Comments
 (0)