fix: 🐛
This commit is contained in:
parent
4a39941352
commit
5966e06029
1 changed files with 4 additions and 2 deletions
|
|
@ -139,8 +139,10 @@ export default function ReplyNoteList({ event, className }: { event: NEvent; cla
|
||||||
}
|
}
|
||||||
|
|
||||||
const onNewReply = (evt: NEvent) => {
|
const onNewReply = (evt: NEvent) => {
|
||||||
if (replies.some((reply) => reply.id === evt.id)) return
|
setReplies((pre) => {
|
||||||
setReplies((pre) => [...pre, evt])
|
if (pre.some((reply) => reply.id === evt.id)) return pre
|
||||||
|
return [...pre, evt]
|
||||||
|
})
|
||||||
if (evt.pubkey === pubkey) {
|
if (evt.pubkey === pubkey) {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
highlightReply(evt.id)
|
highlightReply(evt.id)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue