Skip to content

Commit

Permalink
fix: replace ',' -> /,/g로 변경해서 모든 콤마 지우는 것으로 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
jinhokim98 committed Sep 26, 2024
1 parent 57cb197 commit 3d855ed
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client/src/hooks/useMembersStep.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,15 +88,15 @@ const useMembersStep = ({billInfo, setBillInfo, currentMembers, setStep}: Props)
});
postBill({
title: billInfo.title,
price: Number(billInfo.price.replace(',', '')),
price: Number(billInfo.price.replace(/,/g, '')),
memberIds: billInfo.members.map(member =>
member.id === -1 ? newMembers.members.find(m => m.name === member.name)?.id || member.id : member.id,
),
});
} else {
postBill({
title: billInfo.title,
price: Number(billInfo.price.replace(',', '')),
price: Number(billInfo.price.replace(/,/g, '')),
memberIds: billInfo.members.map(({id}) => id),
});
}
Expand Down

0 comments on commit 3d855ed

Please sign in to comment.