aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Controller
diff options
context:
space:
mode:
authorShadowghost <Shadowghost@users.noreply.github.com>2026-09-15 11:16:09 -0400
committerCody Robibero <cody@robibe.ro>2026-09-15 11:16:09 -0400
commit6a317f45ce5def14b4feccc4ae84f2e27441b997 (patch)
treecf379969b969517367c181531fecb16bf639baeb /MediaBrowser.Controller
parent8c70920673ba82f2fec940574add6d65aa21be5e (diff)
Backport pull request #17950 from jellyfin/release-12.z
Fix collection creation when the collections library was just added Original-merge: 3c698bab7fb7c607e726a0bf79f0bb0f7616e962 Merged-by: crobibero <cody@robibe.ro> Backported-by: Cody Robibero <cody@robibe.ro>
Diffstat (limited to 'MediaBrowser.Controller')
-rw-r--r--MediaBrowser.Controller/Entities/AggregateFolder.cs17
1 files changed, 17 insertions, 0 deletions
diff --git a/MediaBrowser.Controller/Entities/AggregateFolder.cs b/MediaBrowser.Controller/Entities/AggregateFolder.cs
index a02802f41e..bb770fc6f3 100644
--- a/MediaBrowser.Controller/Entities/AggregateFolder.cs
+++ b/MediaBrowser.Controller/Entities/AggregateFolder.cs
@@ -54,6 +54,23 @@ namespace MediaBrowser.Controller.Entities
public string[] PhysicalLocationsList { get; set; }
+ // Children caches the resolved items, _childrenIds the ids they were loaded from. Clearing
+ // only the former sends the next read back through LoadChildren, which replays the stale
+ // id list, so a caller invalidating this folder has to drop both.
+ public override IEnumerable<BaseItem> Children
+ {
+ get => base.Children;
+ set
+ {
+ if (value is null)
+ {
+ ClearCache();
+ }
+
+ base.Children = value;
+ }
+ }
+
public override bool CanDelete()
{
return false;