Skip to content

Commit 44a1615

Browse files
authored
Merge pull request #480 from trycompai/main
[comp] Production Deploy
2 parents fce4146 + 6a4e00e commit 44a1615

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

apps/app/src/components/google-sign-in.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,11 @@ export function GoogleSignIn({
2323
? `/api/auth/invitation?code=${inviteCode}`
2424
: "/";
2525

26+
const callbackURL = new URL(redirectTo, window.location.origin);
27+
2628
await authClient.signIn.social({
2729
provider: "google",
30+
callbackURL: callbackURL.toString(),
2831
});
2932
};
3033

apps/app/src/utils/auth.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ export const auth = betterAuth({
3535
database: prismaAdapter(db, {
3636
provider: "postgresql",
3737
}),
38+
trustedOrigins: [
39+
"http://localhost:3000",
40+
"https://app.trycomp.ai",
41+
"https://dev.trycomp.ai",
42+
],
3843
advanced: {
3944
database: {
4045
// This will enable us to fall back to DB for ID generation.

0 commit comments

Comments
 (0)