Skip to content

Commit

Permalink
fix: 모임 생성 중복생성 방지 (#168)
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrevile authored Aug 27, 2024
1 parent ab56385 commit 26692ff
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import { Txt, Button } from '@sambad/sds/components';
import { colors } from '@sambad/sds/theme';
import debounce from 'lodash-es/debounce';
import { useForm } from 'react-hook-form';

import { Params as MeetingParams } from '@/common/apis/queries/useCreateMeeting';
Expand Down Expand Up @@ -55,7 +56,10 @@ export const IntroInfoForm = () => {
meetingTypeIds: meetingTypeIds ? meetingTypeIds.split(',').map(Number) : [],
} as MeetingParams;

createMeeting(meetingParams, meetingMemberParams);
const mutate = debounce(() => {
createMeeting(meetingParams, meetingMemberParams);
}, 300);
mutate();
}
// 모임원인 경우 모임 가입 초대코드
if (role.params === 'MEMBER') {
Expand Down

0 comments on commit 26692ff

Please sign in to comment.