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
@@ -136,6 +136,8 @@ public class OtherVideoFolderScanner : LocalFolderScanner, IOtherVideoFolderScan
"UPDATE: Etag has changed for folder {Folder}",
otherVideoFolder);
var hasErrors = false;
foreach (string file in allFiles.OrderBy(identity))
{
Either<BaseError, MediaItemScanResult<OtherVideo>> maybeVideo = await _otherVideoRepository
@@ -148,6 +150,7 @@ public class OtherVideoFolderScanner : LocalFolderScanner, IOtherVideoFolderScan
foreach (BaseError error in maybeVideo.LeftToSeq())
{
_logger.LogWarning("Error processing other video at {Path}: {Error}", file, error.Value);
hasErrors = true;
}
foreach (MediaItemScanResult<OtherVideo> result in maybeVideo.RightToSeq())
@@ -156,10 +159,14 @@ public class OtherVideoFolderScanner : LocalFolderScanner, IOtherVideoFolderScan
{
await _searchIndex.RebuildItems(_searchRepository, new List<int> { result.Item.Id });
}
await _libraryRepository.SetEtag(libraryPath, knownFolder, otherVideoFolder, etag);
}
}
// only do this once per folder and only if all files processed successfully
if (!hasErrors)
{
await _libraryRepository.SetEtag(libraryPath, knownFolder, otherVideoFolder, etag);
}
}
foreach (string path in await _otherVideoRepository.FindOtherVideoPaths(libraryPath))