From fd12a98b1beb279e65ad6b4c6365a0ddb75e2bec Mon Sep 17 00:00:00 2001 From: infinite-persistence Date: Fri, 6 May 2022 15:04:05 +0800 Subject: [PATCH] Refresh commented-channels list when deleting a comment Users should be allowed to clear their past comments and switch to another channel. --- flow-typed/Lbry.js | 1 + ui/redux/actions/comments.js | 3 +++ 2 files changed, 4 insertions(+) diff --git a/flow-typed/Lbry.js b/flow-typed/Lbry.js index 89451386b..ac54357fd 100644 --- a/flow-typed/Lbry.js +++ b/flow-typed/Lbry.js @@ -155,6 +155,7 @@ declare type CommentPinResponse = { declare type CommentAbandonResponse = { // keyed by the CommentId given abandoned: boolean, + claim_id: string, }; declare type ChannelListResponse = { diff --git a/ui/redux/actions/comments.js b/ui/redux/actions/comments.js index c67d2d368..0f4b18789 100644 --- a/ui/redux/actions/comments.js +++ b/ui/redux/actions/comments.js @@ -831,6 +831,9 @@ export function doCommentAbandon( comment_id: commentId, }, }); + + // Update the commented-channels list. + dispatch(doFetchMyCommentedChannels(result.claim_id)); } else { dispatch({ type: ACTIONS.COMMENT_ABANDON_FAILED,