feat: add prod url
This commit is contained in:
@@ -10,7 +10,7 @@ const app = getHono();
|
||||
app.use(
|
||||
"/api/*",
|
||||
cors({
|
||||
origin: 'https://money.koon.us',
|
||||
origin: ['https://money.koon.us','http://localhost:8081'],
|
||||
allowMethods: ["POST", "GET", "OPTIONS"],
|
||||
allowHeaders: ["Content-Type", "Authorization"],
|
||||
credentials: true,
|
||||
|
||||
@@ -5,7 +5,7 @@ export default function Auth() {
|
||||
const onLogin = () => {
|
||||
authClient.signIn.oauth2({
|
||||
providerId: "koon-family",
|
||||
callbackURL: "http://localhost:8081"
|
||||
callbackURL: process.env.NODE_ENV == 'production' ? 'https://money.koon.us' : "http://localhost:8081"
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user