fix(EditLabel): don't show the edit label if comment.original.content is identical to comment.content

This commit is contained in:
plebeius.eth
2023-09-22 14:08:10 +02:00
parent 8758996c97
commit bcbf311b95
+2 -2
View File
@@ -40,7 +40,7 @@ const EditLabel = ({ commentCid, className }) => {
return (
<>
<OriginalCommentModal isOpen={isOriginalCommentModalOpen} closeModal={() => setIsOriginalCommentModalOpen(false)} comment={comment} />
{comment.edit && (
{comment.edit && comment.original?.content !== comment?.content ? (
<>
<br />
<span className={className}>
@@ -51,7 +51,7 @@ const EditLabel = ({ commentCid, className }) => {
)
</span>
</>
)}
) : null}
{(editedCommentState === 'pending' || editedCommentState === 'failed') && conditionsString ? (
<>
<br />