aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Extensions/DtoExtensions.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Jellyfin.Api/Extensions/DtoExtensions.cs')
-rw-r--r--Jellyfin.Api/Extensions/DtoExtensions.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/Jellyfin.Api/Extensions/DtoExtensions.cs b/Jellyfin.Api/Extensions/DtoExtensions.cs
index 5e338b67d..9e784f7c4 100644
--- a/Jellyfin.Api/Extensions/DtoExtensions.cs
+++ b/Jellyfin.Api/Extensions/DtoExtensions.cs
@@ -1,6 +1,6 @@
using System;
using System.Collections.Generic;
-using Jellyfin.Api.Helpers;
+using System.Security.Claims;
using Jellyfin.Extensions;
using MediaBrowser.Controller.Dto;
using MediaBrowser.Model.Entities;
@@ -22,14 +22,14 @@ namespace Jellyfin.Api.Extensions
/// Legacy order: 2.
/// </remarks>
/// <param name="dtoOptions">DtoOptions object.</param>
- /// <param name="request">Current request.</param>
+ /// <param name="user">Current claims principal.</param>
/// <returns>Modified DtoOptions object.</returns>
internal static DtoOptions AddClientFields(
- this DtoOptions dtoOptions, HttpRequest request)
+ this DtoOptions dtoOptions, ClaimsPrincipal user)
{
dtoOptions.Fields ??= Array.Empty<ItemFields>();
- string? client = ClaimHelpers.GetClient(request.HttpContext.User);
+ string? client = user.GetClient();
// No client in claim
if (string.IsNullOrEmpty(client))