From a7a7001542e173255f7afcf5ad1f48ed9c62c8e3 Mon Sep 17 00:00:00 2001 From: "plebeius.eth" Date: Tue, 1 Aug 2023 14:48:47 +0200 Subject: [PATCH] fix account address update after using signer --- src/components/modals/ReplyModal.jsx | 3 ++- src/components/views/Board.jsx | 3 ++- src/components/views/Catalog.jsx | 3 ++- src/components/views/Thread.jsx | 3 ++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/components/modals/ReplyModal.jsx b/src/components/modals/ReplyModal.jsx index 96fb2235..c15ce2fa 100755 --- a/src/components/modals/ReplyModal.jsx +++ b/src/components/modals/ReplyModal.jsx @@ -178,6 +178,7 @@ const ReplyModal = ({ isOpen, closeModal }) => { ...prevPublishCommentOptions, author: { displayName: nameRef.current.value || undefined, + address: account?.author.address, }, content: commentRef.current.value || undefined, link: linkRef.current.value || undefined, @@ -215,7 +216,7 @@ const ReplyModal = ({ isOpen, closeModal }) => { signer, author: { ...prevPublishCommentOptions.author, - address: signer?.address + address: signer?.address, }, }; diff --git a/src/components/views/Board.jsx b/src/components/views/Board.jsx index 582f3e2d..23e7b945 100755 --- a/src/components/views/Board.jsx +++ b/src/components/views/Board.jsx @@ -445,6 +445,7 @@ const Board = () => { ...prevPublishCommentOptions, author: { displayName: nameRef.current.value || undefined, + address: account?.author.address, }, title: subjectRef.current.value || undefined, content: commentRef.current.value || undefined, @@ -482,7 +483,7 @@ const Board = () => { signer, author: { ...prevPublishCommentOptions.author, - address: signer?.address + address: signer?.address, }, }; diff --git a/src/components/views/Catalog.jsx b/src/components/views/Catalog.jsx index 029a9dc3..743b0ac6 100755 --- a/src/components/views/Catalog.jsx +++ b/src/components/views/Catalog.jsx @@ -292,6 +292,7 @@ const Catalog = () => { ...prevPublishCommentOptions, author: { displayName: nameRef.current.value || undefined, + address: account?.author.address, }, title: subjectRef.current.value || undefined, content: commentRef.current.value || undefined, @@ -329,7 +330,7 @@ const Catalog = () => { signer, author: { ...prevPublishCommentOptions.author, - address: signer?.address + address: signer?.address, }, }; diff --git a/src/components/views/Thread.jsx b/src/components/views/Thread.jsx index a3988d30..5ed440d0 100755 --- a/src/components/views/Thread.jsx +++ b/src/components/views/Thread.jsx @@ -386,6 +386,7 @@ const Thread = () => { ...prevPublishCommentOptions, author: { displayName: nameRef.current.value || undefined, + address: account?.author.address, }, content: commentRef.current.value || undefined, link: linkRef.current.value || undefined, @@ -423,7 +424,7 @@ const Thread = () => { signer, author: { ...prevPublishCommentOptions.author, - address: signer?.address + address: signer?.address, }, };