From de1bbcf66847cb890b0b2d29ebb3dabcfa12927d Mon Sep 17 00:00:00 2001 From: Kenneth Skovhede Date: Mon, 7 Jul 2025 16:16:39 +0200 Subject: [PATCH] Fixed create order sorting The create order was sorting strings, not numbers. --- Duplicati/WebserverCore/Services/BackupListService.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Duplicati/WebserverCore/Services/BackupListService.cs b/Duplicati/WebserverCore/Services/BackupListService.cs index 7ae9fef5c..198bb1ce7 100644 --- a/Duplicati/WebserverCore/Services/BackupListService.cs +++ b/Duplicati/WebserverCore/Services/BackupListService.cs @@ -202,7 +202,13 @@ public class BackupListService(Connection connection) : IBackupListService Func? selector = sort switch { "name" => x => x.Backup.Name, - "id" => x => x.Backup.ID, + "id" => x => + { + if (long.TryParse(x.Backup.ID, out var id)) + return id; + return -1; + } + , "lastrun" => x => { if (x.Backup.Metadata == null)