Skip to content

A modern, self-hosted backup solution for secure, encrypted backups across local and cloud storage.

fix: resolves incorrect sync source stats on failed syncs.

towfiqid7b2155c5d46
diff --git a/frontend/src/hooks/usePlanSingleActions.tsx b/frontend/src/hooks/usePlanSingleActions.tsx
index 1158bad..bda4382 100644
--- a/frontend/src/hooks/usePlanSingleActions.tsx
+++ b/frontend/src/hooks/usePlanSingleActions.tsx
@@ -51,7 +51,7 @@ export const usePlanSingleActions = (): {
const sortedHistory = [...(plan.backups || [])].sort((a, b) => b.started - a.started);
const activeBackups = sortedHistory.filter((s) => s.inProgress);
const activeRestores = (plan.restores || []).filter((s) => s.status === 'started');
- const lastBackupItem = sortedHistory[0];
+ const lastBackupItem = isSync ? sortedHistory.filter((s) => s.status === 'completed')[0] : sortedHistory[0];
const actionInProgress = activeBackups.length > 0 || activeRestores.length > 0;
const taskPending = pauseMutation.isPending || resumeMutation.isPending || performBackupMutation.isPending;