mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
add null check
This commit is contained in:
parent
0daf52faec
commit
d2658c710c
1 changed files with 6 additions and 0 deletions
|
|
@ -204,6 +204,9 @@ namespace Flow.Launcher.Core.ExternalPlugins.Environments
|
|||
|
||||
private static bool IsUsingPortablePath(string filePath, string pluginEnvironmentName)
|
||||
{
|
||||
if (string.IsNullOrEmpty(filePath))
|
||||
return false;
|
||||
|
||||
// DataLocation.PortableDataPath returns the current portable path, this determines if an out
|
||||
// of date path is also a portable path.
|
||||
var portableAppEnvLocation = $"UserData\\{DataLocation.PluginEnvironments}\\{pluginEnvironmentName}";
|
||||
|
|
@ -213,6 +216,9 @@ namespace Flow.Launcher.Core.ExternalPlugins.Environments
|
|||
|
||||
private static bool IsUsingRoamingPath(string filePath)
|
||||
{
|
||||
if (string.IsNullOrEmpty(filePath))
|
||||
return false;
|
||||
|
||||
return filePath.StartsWith(DataLocation.RoamingDataPath);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue