music video nfo multiple artists (#780)
* support multiple artist entries in music video nfo metadata * clean up other video and song etags
This commit is contained in:
@@ -134,6 +134,8 @@ public class SongFolderScanner : LocalFolderScanner, ISongFolderScanner
|
||||
"UPDATE: Etag has changed for folder {Folder}",
|
||||
songFolder);
|
||||
|
||||
var hasErrors = false;
|
||||
|
||||
foreach (string file in allFiles.OrderBy(identity))
|
||||
{
|
||||
Either<BaseError, MediaItemScanResult<Song>> maybeSong = await _songRepository
|
||||
@@ -146,6 +148,7 @@ public class SongFolderScanner : LocalFolderScanner, ISongFolderScanner
|
||||
foreach (BaseError error in maybeSong.LeftToSeq())
|
||||
{
|
||||
_logger.LogWarning("Error processing song at {Path}: {Error}", file, error.Value);
|
||||
hasErrors = true;
|
||||
}
|
||||
|
||||
foreach (MediaItemScanResult<Song> result in maybeSong.RightToSeq())
|
||||
@@ -154,10 +157,14 @@ public class SongFolderScanner : LocalFolderScanner, ISongFolderScanner
|
||||
{
|
||||
await _searchIndex.RebuildItems(_searchRepository, new List<int> { result.Item.Id });
|
||||
}
|
||||
|
||||
await _libraryRepository.SetEtag(libraryPath, knownFolder, songFolder, etag);
|
||||
}
|
||||
}
|
||||
|
||||
// only do this once per folder and only if all files processed successfully
|
||||
if (!hasErrors)
|
||||
{
|
||||
await _libraryRepository.SetEtag(libraryPath, knownFolder, songFolder, etag);
|
||||
}
|
||||
}
|
||||
|
||||
foreach (string path in await _songRepository.FindSongPaths(libraryPath))
|
||||
|
||||
Reference in New Issue
Block a user