update media sync

This commit is contained in:
Luke Pulverenti 2015-09-28 23:35:50 -04:00
parent 8327094df3
commit 0d6580baf3

View File

@ -62,7 +62,7 @@ namespace MediaBrowser.Server.Implementations.FileOrganization
try
{
var result = await organizer.OrganizeEpisodeFile(file.FullName, options, options.OverwriteExistingEpisodes, cancellationToken).ConfigureAwait(false);
if (result.Status == FileSortingStatus.Success && !processedFolders.Contains(file.DirectoryName))
if (result.Status == FileSortingStatus.Success && !processedFolders.Contains(file.DirectoryName, StringComparer.OrdinalIgnoreCase))
{
processedFolders.Add(file.DirectoryName);
}
@ -188,18 +188,7 @@ namespace MediaBrowser.Server.Implementations.FileOrganization
/// <param name="watchLocations">A list of folders.</param>
private bool IsWatchFolder(string path, IEnumerable<string> watchLocations)
{
// Use GetFullPath to resolve 8.3 naming and path indirections
path = Path.GetFullPath(path);
foreach (var watchFolder in watchLocations)
{
if (String.Equals(path, Path.GetFullPath(watchFolder), StringComparison.OrdinalIgnoreCase))
{
return true;
}
}
return false;
return watchLocations.Contains(path, StringComparer.OrdinalIgnoreCase);
}
}
}