Skip to content

Commit

Permalink
Merge pull request #597 from developerjhp/Fix/reCmt-596
Browse files Browse the repository at this point in the history
[Fix] 댓글 내용 변동없이 수정등록시 발생하는 에러 수정 close #596
  • Loading branch information
developerjhp authored Mar 28, 2022
2 parents 9441cd8 + 3b30eb4 commit d3dc3ee
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions client/src/components/CommentInput/CommentInput.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { useEffect } from 'react';
import { useState } from 'react';
import { CommentInputWrap } from './styled';

Expand Down Expand Up @@ -25,6 +26,10 @@ export default function CommentInput({
// }
// }

useEffect(() => {
if (defaultContent) setComment(defaultContent);
}, []);

const submitValidHandler = () => {
submitCmtHandler(comment);
setComment('');
Expand Down

0 comments on commit d3dc3ee

Please sign in to comment.