mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-07-09 03:04:24 -04:00
Set Parent to current query Item if ParentId is empty (#680)
**Changes** Fixed a faulty change in logic that occurred during the Christmas GPL nightmare. I stepped through Emby 3.5.2 and stumbled over a difference in the query between Jellyfin and Emby, where in Emby, query.ParentId was set to the item itself. So I did a little digging in the old GPLv2 source and found this https://github.com/MediaBrowser/Emby/blob/3.4.1.8/MediaBrowser.Controller/Entities/Folder.cs#L720 **Issues** Fixes #673
This commit is contained in:
parent
bd550ef996
commit
b2ffad9ce9
@ -644,12 +644,9 @@ namespace MediaBrowser.Controller.Entities
|
|||||||
return PostFilterAndSort(items, query, true);
|
return PostFilterAndSort(items, query, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(this is UserRootFolder) && !(this is AggregateFolder))
|
if (!(this is UserRootFolder) && !(this is AggregateFolder) && query.ParentId == Guid.Empty)
|
||||||
{
|
{
|
||||||
if (!query.ParentId.Equals(Guid.Empty))
|
query.Parent = this;
|
||||||
{
|
|
||||||
query.Parent = this;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (RequiresPostFiltering2(query))
|
if (RequiresPostFiltering2(query))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user