1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2026-04-24 22:36:19 -04:00

Fixed getting parent path from a path without another slash

Fixed: Manual Import failing for some paths
This commit is contained in:
Mark McDowall
2019-01-01 15:01:24 -08:00
parent c14b339d80
commit edd6c0bd4c
3 changed files with 21 additions and 1 deletions
@@ -71,10 +71,11 @@ namespace NzbDrone.Common.Extensions
var index = parentPath.LastIndexOfAny(new[] { '\\', '/' });
if (index != -1)
if (index > 0)
{
return parentPath.Substring(0, index);
}
return null;
}