Browse Source

fix: uniq key for Fragment

closed-social-glitch-2
欧醚 1 year ago
parent
commit
af35a02def
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      app/javascript/flavours/glitch/components/status_with_comments.jsx

+ 2
- 2
app/javascript/flavours/glitch/components/status_with_comments.jsx View File

@ -55,7 +55,7 @@ class StatusWithComments extends ImmutablePureComponent {
{childrenWithGrandchildren {childrenWithGrandchildren
.filter((_, idx) => showAll || idx < N) .filter((_, idx) => showAll || idx < N)
.map(({ cid, grandchildrenIds }) => ( .map(({ cid, grandchildrenIds }) => (
<>
<React.Fragment key={cid}>
<StatusContainer <StatusContainer
key={`comment-${cid}`} key={`comment-${cid}`}
id={cid} id={cid}
@ -73,7 +73,7 @@ class StatusWithComments extends ImmutablePureComponent {
{!showAll && grandchildrenIds.size > N && loadMore} {!showAll && grandchildrenIds.size > N && loadMore}
</div> </div>
)} )}
</>
</React.Fragment>
))} ))}
{!showAll && childrenWithGrandchildren.size > N && loadMore} {!showAll && childrenWithGrandchildren.size > N && loadMore}
</div> </div>

Loading…
Cancel
Save