mirror of
https://github.com/Kareadita/Kavita.git
synced 2026-06-05 22:35:17 -04:00
Stats Page Overhaul (#4292)
Co-authored-by: Amelia <77553571+Fesaa@users.noreply.github.com>
This commit is contained in:
@@ -24,17 +24,17 @@ public class DeviceTrackingMiddleware(RequestDelegate next, ILogger<DeviceTracki
|
||||
IClientInfoAccessor clientInfoAccessor,
|
||||
IUserContext userContext)
|
||||
{
|
||||
var endpoint = context.GetEndpoint();
|
||||
var skipTracking = endpoint?.Metadata.GetMetadata<SkipDeviceTrackingAttribute>() != null;
|
||||
|
||||
if (skipTracking)
|
||||
{
|
||||
await next(context);
|
||||
return;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
var endpoint = context.GetEndpoint();
|
||||
var skipTracking = endpoint?.Metadata.GetMetadata<SkipDeviceTrackingAttribute>() != null;
|
||||
|
||||
if (skipTracking)
|
||||
{
|
||||
await next(context);
|
||||
return;
|
||||
}
|
||||
|
||||
var userId = userContext.GetUserId();
|
||||
var clientInfo = clientInfoAccessor.Current;
|
||||
var clientUiFingerprint = clientInfoAccessor.CurrentUiFingerprint; // string from webapp header
|
||||
|
||||
Reference in New Issue
Block a user