aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Server.Implementations/Item
diff options
context:
space:
mode:
authortheguymadmax <171496228+theguymadmax@users.noreply.github.com>2025-12-03 14:04:22 -0500
committerBond_009 <bond.009@outlook.com>2025-12-03 14:04:22 -0500
commit4f020a947ae7e2765a8b04bb56ffe11caf24aeb8 (patch)
tree3ef20845cc5aba0f1f6550c37b4893159622e060 /Jellyfin.Server.Implementations/Item
parent3460d1de3cd0cc710a411640a26c9f43f39f7728 (diff)
Backport pull request #15564 from jellyfin/release-10.11.z
Fix locked fields not saving Original-merge: 0ee81e87be58072e21a3bc69fc1d1d0fbc83974a Merged-by: crobibero <cody@robibe.ro> Backported-by: Bond_009 <bond.009@outlook.com>
Diffstat (limited to 'Jellyfin.Server.Implementations/Item')
-rw-r--r--Jellyfin.Server.Implementations/Item/BaseItemRepository.cs6
1 files changed, 6 insertions, 0 deletions
diff --git a/Jellyfin.Server.Implementations/Item/BaseItemRepository.cs b/Jellyfin.Server.Implementations/Item/BaseItemRepository.cs
index 2c18ce69a..f4bb94349 100644
--- a/Jellyfin.Server.Implementations/Item/BaseItemRepository.cs
+++ b/Jellyfin.Server.Implementations/Item/BaseItemRepository.cs
@@ -618,12 +618,18 @@ public sealed class BaseItemRepository
{
context.BaseItemProviders.Where(e => e.ItemId == entity.Id).ExecuteDelete();
context.BaseItemImageInfos.Where(e => e.ItemId == entity.Id).ExecuteDelete();
+ context.BaseItemMetadataFields.Where(e => e.ItemId == entity.Id).ExecuteDelete();
if (entity.Images is { Count: > 0 })
{
context.BaseItemImageInfos.AddRange(entity.Images);
}
+ if (entity.LockedFields is { Count: > 0 })
+ {
+ context.BaseItemMetadataFields.AddRange(entity.LockedFields);
+ }
+
context.BaseItems.Attach(entity).State = EntityState.Modified;
}
}