[PR #15766] [MERGED] Fix backdrop images being deleted when stored with media #14412

Closed
opened 2026-02-07 07:29:25 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/jellyfin/jellyfin/pull/15766
Author: @theguymadmax
Created: 12/11/2025
Status: Merged
Merged: 12/13/2025
Merged by: @crobibero

Base: release-10.11.zHead: fix-local-background-images


📝 Commits (1)

  • 9b45ec0 Fix backdrop images being deleted when stored with media

📊 Changes

1 file changed (+38 additions, -4 deletions)

View changed files

📝 MediaBrowser.Providers/Manager/ItemImageProvider.cs (+38 -4)

📄 Description

When "Save artwork into media folders" is disabled and backdrop images are stored next to media, running "Replace all metadata" with "Replace existing images" would incorrectly delete backdrop images while preserving other image types (Primary, Logo, Thumb, etc.).

Changes

ItemImageProvider.cs - RemoveImages method

Apply the same conditional logic to backdrop images as singular images:

  • Only delete backdrops if they're in the metadata folder, OR
  • canDeleteLocal is true, OR
  • "Save artwork into media folders" is enabled

ItemImageProvider.cs - MergeImages method

  • Check if backdrop images are stored with media and add to foundImageTypes to prevent replacement

Issues
Fixes #15759


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/jellyfin/jellyfin/pull/15766 **Author:** [@theguymadmax](https://github.com/theguymadmax) **Created:** 12/11/2025 **Status:** ✅ Merged **Merged:** 12/13/2025 **Merged by:** [@crobibero](https://github.com/crobibero) **Base:** `release-10.11.z` ← **Head:** `fix-local-background-images` --- ### 📝 Commits (1) - [`9b45ec0`](https://github.com/jellyfin/jellyfin/commit/9b45ec0780ec7e8dab55df933bb2d3652bab3779) Fix backdrop images being deleted when stored with media ### 📊 Changes **1 file changed** (+38 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `MediaBrowser.Providers/Manager/ItemImageProvider.cs` (+38 -4) </details> ### 📄 Description <!-- Ensure your title is short, descriptive, and in the imperative mood (Fix X, Change Y, instead of Fixed X, Changed Y). For a good inspiration of what to write in commit messages and PRs please review https://chris.beams.io/posts/git-commit/ and our documentation. --> When "Save artwork into media folders" is disabled and backdrop images are stored next to media, running "Replace all metadata" with "Replace existing images" would incorrectly delete backdrop images while preserving other image types (Primary, Logo, Thumb, etc.). **Changes** ItemImageProvider.cs - `RemoveImages` method Apply the same conditional logic to backdrop images as singular images: - Only delete backdrops if they're in the metadata folder, OR - `canDeleteLocal` is true, OR - "Save artwork into media folders" is enabled ItemImageProvider.cs - `MergeImages` method - Check if backdrop images are stored with media and add to `foundImageTypes` to prevent replacement **Issues** Fixes #15759 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-07 07:29:25 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/jellyfin#14412