From 675c19a18b13a63c4a36b1fed59fdb16a1c3b3c0 Mon Sep 17 00:00:00 2001 From: diondiondion Date: Wed, 29 Apr 2026 16:42:23 +0200 Subject: [PATCH] [Glitch] Fix stale collections list after deleting a collection Port b761310823926d7f30e46f401ce17f35027c114e to glitch-soc Signed-off-by: Claire --- .../ui/components/confirmation_modals/delete_collection.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/javascript/flavours/glitch/features/ui/components/confirmation_modals/delete_collection.tsx b/app/javascript/flavours/glitch/features/ui/components/confirmation_modals/delete_collection.tsx index 9c7559df07..d57f6fe393 100644 --- a/app/javascript/flavours/glitch/features/ui/components/confirmation_modals/delete_collection.tsx +++ b/app/javascript/flavours/glitch/features/ui/components/confirmation_modals/delete_collection.tsx @@ -38,8 +38,8 @@ export const ConfirmDeleteCollectionModal: React.FC< const history = useHistory(); const { acct: currentUserName } = useAccount(me) ?? {}; - const onConfirm = useCallback(() => { - void dispatch(deleteCollection({ collectionId: id })); + const onConfirm = useCallback(async () => { + await dispatch(deleteCollection({ collectionId: id })); history.push(`/@${currentUserName}/collections`); }, [dispatch, history, id, currentUserName]);