* Stylecop Rules and Fixes
This commit is contained in:
Qstick
2020-01-03 07:49:24 -05:00
committed by GitHub
parent 63d669178d
commit f77a2feeef
1307 changed files with 8704 additions and 7404 deletions
@@ -33,7 +33,8 @@ namespace NzbDrone.Common.Extensions
var info = new FileInfo(path.Trim());
if (OsInfo.IsWindows && info.FullName.StartsWith(@"\\")) //UNC
//UNC
if (OsInfo.IsWindows && info.FullName.StartsWith(@"\\"))
{
return info.FullName.TrimEnd('/', '\\', ' ');
}
@@ -58,7 +59,11 @@ namespace NzbDrone.Common.Extensions
comparison = DiskProviderBase.PathStringComparison;
}
if (firstPath.Equals(secondPath, comparison.Value)) return true;
if (firstPath.Equals(secondPath, comparison.Value))
{
return true;
}
return string.Equals(firstPath.CleanFilePath(), secondPath.CleanFilePath(), comparison.Value);
}
@@ -92,6 +97,7 @@ namespace NzbDrone.Common.Extensions
{
parentPath = parentPath.TrimEnd(Path.DirectorySeparatorChar);
}
if (childPath != "/" && !parentPath.EndsWith(":\\"))
{
childPath = childPath.TrimEnd(Path.DirectorySeparatorChar);