fix: correct success state handling in user ID fetching logic

This commit is contained in:
Pattadon 2024-11-11 11:03:58 +07:00
parent a04a3a228f
commit 2d79e5d898

View File

@ -102,11 +102,12 @@ export default function ApplyBusiness() {
}
});
}
setSucess(false);
} else {
setSucess(true);
console.error("User ID is undefined.");
}
} catch (error) {
setSucess(true);
console.error("Error fetching user ID:", error);
}
};