From c1e74a8eca0978a6a083b2c83cc9d7338b23a0b0 Mon Sep 17 00:00:00 2001 From: mkljczk Date: Sun, 2 Mar 2025 17:49:41 +0100 Subject: [PATCH] pl-fe: Actually fix the logic Signed-off-by: mkljczk --- .../features/notifications/components/notification.tsx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/packages/pl-fe/src/features/notifications/components/notification.tsx b/packages/pl-fe/src/features/notifications/components/notification.tsx index 435afc4b7..ded878469 100644 --- a/packages/pl-fe/src/features/notifications/components/notification.tsx +++ b/packages/pl-fe/src/features/notifications/components/notification.tsx @@ -218,7 +218,7 @@ const Notification: React.FC = (props) => { const account = accounts[0]; const getHandlers = () => ({ - reply: handleMention, + reply: handleReply, favourite: handleHotkeyFavourite, boost: handleHotkeyBoost, mention: handleMention, @@ -246,6 +246,12 @@ const Notification: React.FC = (props) => { const handleMention = useCallback((e?: KeyboardEvent) => { e?.preventDefault(); + dispatch(replyCompose(status, account)); + }, [account]); + + const handleReply = useCallback((e?: KeyboardEvent) => { + e?.preventDefault(); + if (status) { dispatch(replyCompose(status, account)); } else {