From 59db27de3ac4d4811f038ee06631fef3661e722c Mon Sep 17 00:00:00 2001 From: VaDiM Date: Sat, 7 Dec 2024 15:34:09 +0300 Subject: [PATCH] [GUI] Fix a bug with OpenFolderAfterExport option - Fixed a bug with the OpenFolderAfterExport option when it launched a file instead of opening a folder in some cases --- AssetStudioGUI/Studio.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/AssetStudioGUI/Studio.cs b/AssetStudioGUI/Studio.cs index b32874b..9adaf90 100644 --- a/AssetStudioGUI/Studio.cs +++ b/AssetStudioGUI/Studio.cs @@ -933,6 +933,11 @@ namespace AssetStudioGUI public static void OpenFolderInExplorer(string path) { + if (!path.EndsWith($"{Path.DirectorySeparatorChar}")) + path += Path.DirectorySeparatorChar; + if (!Directory.Exists(path)) + return; + var info = new ProcessStartInfo(path); info.UseShellExecute = true; Process.Start(info);