more linux fixes

This commit is contained in:
kay.one 2013-07-25 23:25:03 -07:00
commit aee31d1bc2
2 changed files with 22 additions and 6 deletions

View file

@ -22,8 +22,9 @@ namespace NzbDrone.Common
public static string CleanFilePath(this string path)
{
Ensure.That(() => path).IsNotNullOrWhiteSpace();
Ensure.That(() => path).IsValidPath();
var info = new FileInfo(path);
var info = new FileInfo(path.Trim());
if (!OsInfo.IsLinux && info.FullName.StartsWith(@"\\")) //UNC
{