diff --git a/src/discussions/comments/comment/CommentEditor.jsx b/src/discussions/comments/comment/CommentEditor.jsx index 70afa449..6b291a1f 100644 --- a/src/discussions/comments/comment/CommentEditor.jsx +++ b/src/discussions/comments/comment/CommentEditor.jsx @@ -29,8 +29,8 @@ function CommentEditor({ const { reasonCodesEnabled, editReasons } = useSelector(selectModerationSettings); const [submitting, dispatch] = useDispatchWithState(); - const canDisplayEditReason = (reasonCodesEnabled && userIsPrivileged && edit - && comment.author !== authenticatedUser.username + const canDisplayEditReason = (reasonCodesEnabled && userIsPrivileged + && edit && comment.author !== authenticatedUser.username ); const editReasonCodeValidation = canDisplayEditReason && { diff --git a/src/discussions/posts/post-editor/PostEditor.jsx b/src/discussions/posts/post-editor/PostEditor.jsx index 44c14701..dd334733 100644 --- a/src/discussions/posts/post-editor/PostEditor.jsx +++ b/src/discussions/posts/post-editor/PostEditor.jsx @@ -91,8 +91,8 @@ function PostEditor({ const { allowAnonymous, allowAnonymousToPeers } = useSelector(selectAnonymousPostingConfig); const { reasonCodesEnabled, editReasons } = useSelector(selectModerationSettings); - const canDisplayEditReason = (reasonCodesEnabled && editExisting && userIsPrivileged - && post.author !== authenticatedUser.username + const canDisplayEditReason = (reasonCodesEnabled && editExisting + && userIsPrivileged && post.author !== authenticatedUser.username ); const editReasonCodeValidation = canDisplayEditReason && {