Skip to content

Commit

Permalink
fix: backup complete event not being used
Browse files Browse the repository at this point in the history
  • Loading branch information
ArnaudLier authored Apr 1, 2024
1 parent 2497819 commit a3bf258
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion resources/scripts/components/server/backups/BackupRow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,14 @@ interface Props {
export default ({ backup, className }: Props) => {
const { mutate } = getServerBackups();

useWebsocketEvent(`${SocketEvent.BACKUP_COMPLETED}:${backup.uuid}` as SocketEvent, (data) => {
useWebsocketEvent(SocketEvent.BACKUP_COMPLETED, (data) => {
try {
const parsed = JSON.parse(data);

if (parsed.uuid != backup.uuid) {
return;
}

mutate(
(data) => ({
...data,
Expand Down

0 comments on commit a3bf258

Please sign in to comment.