make sure the tree has been reloaded before navigating to the new feed subscription

This commit is contained in:
Athou
2025-02-14 13:17:59 +01:00
parent 44bc24c22a
commit 13ad57da10

View File

@@ -39,8 +39,8 @@ export function Subscribe() {
}, },
}) })
const subscribe = useAsyncCallback(client.feed.subscribe, { const subscribe = useAsyncCallback(client.feed.subscribe, {
onSuccess: sub => { onSuccess: async sub => {
dispatch(reloadTree()) await dispatch(reloadTree())
dispatch(redirectToFeed(sub.data)) dispatch(redirectToFeed(sub.data))
}, },
}) })