diff options
| author | theguymadmax <theguymadmax@proton.me> | 2026-02-03 17:41:01 -0500 |
|---|---|---|
| committer | theguymadmax <theguymadmax@proton.me> | 2026-02-03 17:41:01 -0500 |
| commit | 4c751e0a86d805314023b8a750e675f5131ee613 (patch) | |
| tree | b6124b0c08e8d89985c687383a27c9fbcbaf1a24 | |
| parent | 32d80861211031e5ee66d5068679f43335e2bcbd (diff) | |
Normalize names and roles
| -rw-r--r-- | Jellyfin.Server.Implementations/Item/PeopleRepository.cs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Jellyfin.Server.Implementations/Item/PeopleRepository.cs b/Jellyfin.Server.Implementations/Item/PeopleRepository.cs index 355ed6479..e2569241d 100644 --- a/Jellyfin.Server.Implementations/Item/PeopleRepository.cs +++ b/Jellyfin.Server.Implementations/Item/PeopleRepository.cs @@ -74,9 +74,10 @@ public class PeopleRepository(IDbContextFactory<JellyfinDbContext> dbProvider, I /// <inheritdoc /> public void UpdatePeople(Guid itemId, IReadOnlyList<PersonInfo> people) { - foreach (var item in people.Where(e => e.Role is null)) + foreach (var person in people) { - item.Role = string.Empty; + person.Name = person.Name.Trim(); + person.Role = person.Role?.Trim() ?? string.Empty; } // multiple metadata providers can provide the _same_ person |
