Ignore extra spaces in path when not running on Windows

(cherry picked from commit 6d0f10b877912edef21232c64339cc6548d9690e)
pull/2269/head
Mark McDowall 3 months ago committed by Bogdan
parent 14250e9634
commit 13c538ff58

@ -147,14 +147,14 @@ namespace NzbDrone.Common.Extensions
return false;
}
if (path.Trim() != path)
{
return false;
}
// Only check for leading or trailing spaces for path when running on Windows.
if (OsInfo.IsWindows)
{
if (path.Trim() != path)
{
return false;
}
var directoryInfo = new DirectoryInfo(path);
while (directoryInfo != null)

Loading…
Cancel
Save