Backport pull request #11633 from jellyfin/release-10.9.z

Allow empty user id when getting device list

Original-merge: a5d60c4521

Merged-by: crobibero <cody@robibe.ro>

Backported-by: Joshua M. Boniface <joshua@boniface.me>
pull/11711/head
crobibero 4 months ago committed by Joshua M. Boniface
parent 9b978578ce
commit 77c3ddc7ca

@ -179,7 +179,7 @@ namespace Jellyfin.Server.Implementations.Devices
.SelectMany(d => dbContext.DeviceOptions.Where(o => o.DeviceId == d.DeviceId).DefaultIfEmpty(), (d, o) => new { Device = d, Options = o })
.AsAsyncEnumerable();
if (userId.HasValue)
if (!userId.IsNullOrEmpty())
{
var user = _userManager.GetUserById(userId.Value);
if (user is null)

Loading…
Cancel
Save