Skip to content

Commit 46358de

Browse files
committed
Disallow writing empty comments velopert#168
1 parent 029b782 commit 46358de

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/containers/post/PostCommentsWriteContainer.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ const PostCommentsWriteContainer: React.FC<PostCommentsWriteContainerProps> = ({
4848
storage.setItem(`comment_before_login:${postId}`, comment);
4949
return requireLogin();
5050
}
51+
if (comment === '') return;
5152
try {
5253
await writeComment({
5354
variables: {

0 commit comments

Comments
 (0)