Skip to content

Commit

Permalink
Fix: 유저 정보 등록 API에 누락된 userId 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
sscoderati committed Jan 26, 2024
1 parent a8e22ae commit 67df5dc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pages/register/RegisterCompany.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const RegisterCompany = () => {
const isDarkMode = useThemeStore((state) => state.isDarkMode);
const toggleDarkMode = useThemeStore((state) => state.toggleDarkMode);
const userId = useAuthStore((state) => state.userId);
const userInfo: UserInfoType = useLocation().state;
const userInfo: Omit<UserInfoType, "userId"> = useLocation().state;
const [isCodeSame, setIsCodeSame] = useState<null | boolean>(null);
const [codeChecked, setCodeChecked] = useState<null | boolean>(null);
const [uploadedURL, setUploadedURL] = useState("");
Expand Down Expand Up @@ -124,7 +124,7 @@ const RegisterCompany = () => {
formData.append("businessCard", data.businessCard[0]);

try {
await registerUserInfo(userInfo);
await registerUserInfo({ userId: userId.toString(), ...userInfo });
await registerCompanyInfo(formData, false);
showToast({
message: "회원 가입 완료! 다시 로그인 해주세요!",
Expand Down

0 comments on commit 67df5dc

Please sign in to comment.