Skip to content

Commit

Permalink
Merge pull request #121 from hufs-sports-live/fix/comment-value
Browse files Browse the repository at this point in the history
[FIX] value가 비었을 때 댓글이 등록되지 않도록 수정
  • Loading branch information
seongminn authored Nov 30, 2023
2 parents d626638 + 3f87db5 commit 217f7f5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/components/match/CommentForm/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ export default function CommentForm({
payload: MatchCommentPayload,
) => {
e.preventDefault();

if (inputValue.trim() === '') return;

mutate({ ...payload, gameTeamId: selectedTeamId });
setInputValue('');
scrollToBottom();
Expand Down

0 comments on commit 217f7f5

Please sign in to comment.