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:
Jason Dove
2022-05-02 12:32:15 -05:00
committed by GitHub
parent 973dd4b53d
commit 8ba6374165
26 changed files with 12960 additions and 42 deletions
+9 -2
View File
@@ -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))