From 52ebf6ae8f050fcbdf675529a97cfbbfcca4953a Mon Sep 17 00:00:00 2001 From: Patrick Barron Date: Wed, 22 Jul 2020 14:53:32 -0400 Subject: [PATCH] Move DisplayPreferencesManager.cs to Users namespace --- .../{ => Users}/DisplayPreferencesManager.cs | 2 +- MediaBrowser.Api/DisplayPreferencesService.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename Jellyfin.Server.Implementations/{ => Users}/DisplayPreferencesManager.cs (96%) diff --git a/Jellyfin.Server.Implementations/DisplayPreferencesManager.cs b/Jellyfin.Server.Implementations/Users/DisplayPreferencesManager.cs similarity index 96% rename from Jellyfin.Server.Implementations/DisplayPreferencesManager.cs rename to Jellyfin.Server.Implementations/Users/DisplayPreferencesManager.cs index 132e74c6aa..29ec6e706e 100644 --- a/Jellyfin.Server.Implementations/DisplayPreferencesManager.cs +++ b/Jellyfin.Server.Implementations/Users/DisplayPreferencesManager.cs @@ -3,7 +3,7 @@ using System.Linq; using Jellyfin.Data.Entities; using MediaBrowser.Controller; -namespace Jellyfin.Server.Implementations +namespace Jellyfin.Server.Implementations.Users { /// /// Manages the storage and retrieval of display preferences through Entity Framework. diff --git a/MediaBrowser.Api/DisplayPreferencesService.cs b/MediaBrowser.Api/DisplayPreferencesService.cs index b95ab0dfde..cca2092e97 100644 --- a/MediaBrowser.Api/DisplayPreferencesService.cs +++ b/MediaBrowser.Api/DisplayPreferencesService.cs @@ -148,7 +148,7 @@ namespace MediaBrowser.Api foreach (var key in request.CustomPrefs.Keys.Where(key => key.StartsWith("homesection"))) { - var order = int.Parse(key.Substring("homesection".Length)); + var order = int.Parse(key.AsSpan().Slice("homesection".Length)); if (!Enum.TryParse(request.CustomPrefs[key], true, out var type)) { type = order < 7 ? defaults[order] : HomeSectionType.None;