diff options
| author | Cody Robibero <cody@robibe.ro> | 2022-08-14 09:49:27 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-08-14 09:49:27 -0700 |
| commit | 8ba83e41aee816c0c098b50296fb668202570baf (patch) | |
| tree | 50e07c2bb928c160b2f3a346743d282ef24f7d74 | |
| parent | 12794d184aca2cf81eee8842d5adb8581e498faf (diff) | |
| parent | d83b1c0f5a227303feb7b3c5af095cf0562d1795 (diff) | |
Merge pull request #7845 from utkuozdemir/fix/photos-lib-dir-with-single-video
| -rw-r--r-- | CONTRIBUTORS.md | 1 | ||||
| -rw-r--r-- | Emby.Server.Implementations/Library/Resolvers/Movies/MovieResolver.cs | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 87086a728..a7d2b2e40 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -225,3 +225,4 @@ - [gnuyent](https://github.com/gnuyent) - [Matthew Jones](https://github.com/matthew-jones-uk) - [Jakob Kukla](https://github.com/jakobkukla) + - [Utku Ă–zdemir](https://github.com/utkuozdemir) diff --git a/Emby.Server.Implementations/Library/Resolvers/Movies/MovieResolver.cs b/Emby.Server.Implementations/Library/Resolvers/Movies/MovieResolver.cs index fe4ccd6ac..a60251dac 100644 --- a/Emby.Server.Implementations/Library/Resolvers/Movies/MovieResolver.cs +++ b/Emby.Server.Implementations/Library/Resolvers/Movies/MovieResolver.cs @@ -464,7 +464,9 @@ namespace Emby.Server.Implementations.Library.Resolvers.Movies var result = ResolveVideos<T>(parent, fileSystemEntries, SupportsMultiVersion, collectionType, parseName) ?? new MultiItemResolverResult(); - if (result.Items.Count == 1) + var isPhotosCollection = string.Equals(collectionType, CollectionType.HomeVideos, StringComparison.OrdinalIgnoreCase) + || string.Equals(collectionType, CollectionType.Photos, StringComparison.OrdinalIgnoreCase); + if (!isPhotosCollection && result.Items.Count == 1) { var videoPath = result.Items[0].Path; var hasPhotos = photos.Any(i => !PhotoResolver.IsOwnedByResolvedMedia(videoPath, i.Name)); |
