From a5f9cd353be22d66fe5d637a668423544a661980 Mon Sep 17 00:00:00 2001 From: omgbeez <251408589+omgbeez@users.noreply.github.com> Date: Fri, 13 Feb 2026 13:22:41 -0500 Subject: [PATCH] SqLite doesn't support OrderBy on DateTimeOffset types Sorting will require a copy to fix this for the moment, could probably change the underlying type later to prevent this. --- server/RdtClient.Data/Data/TorrentData.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/RdtClient.Data/Data/TorrentData.cs b/server/RdtClient.Data/Data/TorrentData.cs index e790b1a..a01f0fe 100644 --- a/server/RdtClient.Data/Data/TorrentData.cs +++ b/server/RdtClient.Data/Data/TorrentData.cs @@ -12,11 +12,11 @@ public class TorrentData(DataContext dataContext) : ITorrentData .AsNoTracking() .AsSplitQuery() .Include(m => m.Downloads) - .OrderBy(m => m.Priority ?? 9999) - .ThenBy(m => m.Added) .ToListAsync(); - return torrents; + return torrents.OrderBy(m => m.Priority ?? 9999) + .ThenBy(m => m.Added) + .ToList(); } public async Task GetById(Guid torrentId)