aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Library/ResolverHelper.cs
diff options
context:
space:
mode:
authorMikal Stordal <mikalstordal@gmail.com>2024-03-24 01:11:45 +0100
committerMikal Stordal <mikalstordal@gmail.com>2024-06-11 02:01:15 +0200
commit0cf8b376acb9bb59be93865c566735df39490d0d (patch)
tree6662dfc7a87918a0d8859a7b3260ff741dda44c9 /Emby.Server.Implementations/Library/ResolverHelper.cs
parent8c76900470911a784b7bcbcf0d0bea24f3c6a65a (diff)
Don't expect `BaseItem` to be a movie/video file.
This fix is mainly so I can mass-add series _and_ movie entries using a `IMultiItemResolver` without having to resort to complicated logic using _both_ a `IItemResolver` and a `IMultiItemResolver` by splitting up what gets added where. I've also added three new interface methods to the `IDirectoryService`, one of which is used in the modified `ResolverHelper.SetInitialItemValues(…)` to get the file system entry info for the item regardless of which type the file system entry is. In my local testing so far I haven't found any issues introduced by this change.
Diffstat (limited to 'Emby.Server.Implementations/Library/ResolverHelper.cs')
-rw-r--r--Emby.Server.Implementations/Library/ResolverHelper.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Emby.Server.Implementations/Library/ResolverHelper.cs b/Emby.Server.Implementations/Library/ResolverHelper.cs
index 52be76217..c9e3a4daf 100644
--- a/Emby.Server.Implementations/Library/ResolverHelper.cs
+++ b/Emby.Server.Implementations/Library/ResolverHelper.cs
@@ -39,7 +39,7 @@ namespace Emby.Server.Implementations.Library
item.GetParents().Any(i => i.IsLocked);
// Make sure DateCreated and DateModified have values
- var fileInfo = directoryService.GetFile(item.Path);
+ var fileInfo = directoryService.GetFileSystemEntry(item.Path);
if (fileInfo is null)
{
return false;