Last of the Year - Page Offset, Device-bound Reading Profiles, and more! (#4313)

Co-authored-by: Amelia <77553571+Fesaa@users.noreply.github.com>
Co-authored-by: DieselTech <30128380+DieselTech@users.noreply.github.com>
Co-authored-by: Alex George <xzeroknightx@gmail.com>
Co-authored-by: Lucas Winther <lucasw89@live.dk>
Co-authored-by: Toni Kielo <toni.kielo@gmail.com>
Co-authored-by: Patrick Orave <oravep@gmail.com>
This commit is contained in:
Joe Milazzo
2025-12-31 12:01:55 -07:00
committed by GitHub
parent 7304db7e2a
commit 6d1c7a4ff5
149 changed files with 13482 additions and 1367 deletions
+3 -2
View File
@@ -399,6 +399,7 @@ public class ClientDeviceService(DataContext context, IMapper mapper, ILogger<Cl
private async Task UpdateDeviceActivityAsync(ClientDevice device, ClientInfoData? newClientInfo)
{
device.LastSeenUtc = DateTime.UtcNow;
context.Entry(device).State = EntityState.Modified;
if (HasMeaningfulChanges(device.CurrentClientInfo, newClientInfo))
{
@@ -420,8 +421,8 @@ public class ClientDeviceService(DataContext context, IMapper mapper, ILogger<Cl
// Their LastSeenUtc is equally valid
logger.LogDebug(ex, "Concurrency conflict updating device {DeviceId}, ignoring", device.Id);
// Detach to prevent tracking issues
context.Entry(device).State = EntityState.Detached;
// Reload the entity from database to get current state
await context.Entry(device).ReloadAsync();
}
}