Survey at account deletion (#1561)

* redirect to /cancellation

* relative path

* base URL check added
This commit is contained in:
Syed Ali Shahbaz 2022-01-19 21:33:51 +05:30 committed by GitHub
parent b75e384a2d
commit e52e1e3e23
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -124,8 +124,11 @@ function SettingsView(props: ComponentProps<typeof Settings> & { localeProp: str
}).catch((e) => {
console.error(`Error Removing user: ${props.user.id}, email: ${props.user.email} :`, e);
});
// signout;
if (process.env.NEXT_PUBLIC_BASE_URL === "https://app.cal.com") {
signOut({ callbackUrl: "https://cal.com/cancellation" });
} else {
signOut({ callbackUrl: "/auth/logout" });
}
};
const localeOptions = useMemo(() => {