mirror of
https://github.com/BililiveRecorder/BililiveRecorder.git
synced 2024-11-16 03:32:20 +08:00
WPF: Fix WorkDirectoryLoader regex
This commit is contained in:
parent
7ec8b1d405
commit
7e2f0e4b49
|
@ -21,7 +21,7 @@ namespace BililiveRecorder.WPF
|
|||
var exePath = Assembly.GetEntryAssembly().Location;
|
||||
this.basePath = string.IsNullOrWhiteSpace(exePath) ? Environment.CurrentDirectory : Path.GetDirectoryName(exePath);
|
||||
|
||||
if (Regex.IsMatch(this.basePath, @"^.*\\app-\d\.\d\.\d\\?$") && File.Exists(Path.Combine(this.basePath, "..", "Update.exe")))
|
||||
if (Regex.IsMatch(this.basePath, @"^.*\\app-\d+\.\d+\.\d+\\?$") && File.Exists(Path.Combine(this.basePath, "..", "Update.exe")))
|
||||
this.basePath = Path.Combine(this.basePath, "..");
|
||||
|
||||
this.basePath = Path.GetFullPath(this.basePath);
|
||||
|
|
Loading…
Reference in New Issue
Block a user