diff options
| author | JPVenson <github@jpb.email> | 2025-03-25 15:12:48 +0000 |
|---|---|---|
| committer | JPVenson <github@jpb.email> | 2025-03-25 15:12:48 +0000 |
| commit | 850f1c79f1319de56a300c1d62565c9b2793b7d8 (patch) | |
| tree | f307a380c63d80809fed23c7ce2c8a0d0aba5de8 /MediaBrowser.Controller/Entities/BaseItem.cs | |
| parent | ef7f6fc8a97118df7f410a7afa2f501f3f4ca3e2 (diff) | |
| parent | 671d801d9f734665d0acbd441246712ad2e3d91f (diff) | |
Merge branch 'master' into feature/DatabaseRefactor
Diffstat (limited to 'MediaBrowser.Controller/Entities/BaseItem.cs')
| -rw-r--r-- | MediaBrowser.Controller/Entities/BaseItem.cs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/MediaBrowser.Controller/Entities/BaseItem.cs b/MediaBrowser.Controller/Entities/BaseItem.cs index f8872e51f..e20679084 100644 --- a/MediaBrowser.Controller/Entities/BaseItem.cs +++ b/MediaBrowser.Controller/Entities/BaseItem.cs @@ -920,7 +920,7 @@ namespace MediaBrowser.Controller.Entities // Remove from middle if surrounded by spaces sortable = sortable.Replace(" " + search + " ", " ", StringComparison.Ordinal); - // Remove from end if followed by a space + // Remove from end if preceeded by a space if (sortable.EndsWith(" " + search, StringComparison.Ordinal)) { sortable = sortable.Remove(sortable.Length - (search.Length + 1)); @@ -1776,7 +1776,6 @@ namespace MediaBrowser.Controller.Entities public void AddStudio(string name) { ArgumentException.ThrowIfNullOrEmpty(name); - var current = Studios; if (!current.Contains(name, StringComparison.OrdinalIgnoreCase)) @@ -1795,7 +1794,7 @@ namespace MediaBrowser.Controller.Entities public void SetStudios(IEnumerable<string> names) { - Studios = names.Distinct().ToArray(); + Studios = names.Trimmed().Distinct().ToArray(); } /// <summary> |
