Skip to content

Commit

Permalink
sdp-tech#78 feat: test users/signup
Browse files Browse the repository at this point in the history
  • Loading branch information
eujin-shin committed Jun 5, 2024
1 parent 8002d8c commit 138df0d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/Auth/BasicForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,15 @@ export default function BasicForm({ navigation, route }: FormProps) {
area: form.region,
};
const response = await request.post(`users/signup/`, params, {});
if (response?.status === 200) {
if (response?.status === 201) {
console.log(params);
setSplash(true);
setTimeout(() => {
navigation.getParent()?.navigate('Home');
}, 3000);
} else if (response?.status === 500) {
console.log(response);
Alert.alert('이미 가입된 이메일입니다.');
} else {
console.log(response);
Alert.alert('가입에 실패했습니다.');
Expand Down

0 comments on commit 138df0d

Please sign in to comment.