We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 45019fc commit 36ee9fcCopy full SHA for 36ee9fc
1 file changed
src/components/User/CompleteProfile.tsx
@@ -72,8 +72,11 @@ const CompleteProfile: React.FC = () => {
72
);
73
74
// Profile completed successfully, redirect to home
75
- navigate("/?auth=success");
76
- window.location.reload(); // Reload to update auth state
+ // navigate("/?auth=success");
+ // window.location.reload(); // Reload to update auth state
77
+ // Use PUBLIC_URL to get the correct base path
78
+ const baseUrl = process.env.PUBLIC_URL || "";
79
+ window.location.href = `${baseUrl}/?auth=success`;
80
} catch (err: unknown) {
81
// setError(err.response?.data?.message || 'Failed to complete profile');
82
if (axios.isAxiosError(err)) {
0 commit comments