robschilder
06/16/2023, 8:58 AM(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/.test(r))?"http://"+i.host:"https://"+i.host:i.protocol+"//"+i.host}catch(e){}if(t.startsWith("/"))throw Error("Please provide a valid domain name");if(0===t.indexOf(".")&&(t=t.substr(1)),(-1!==t.indexOf(".")||t.startsWith("localhost"))&&!t.startsWith("http://")&&!t.startsWith("https://")){t="https://"+t;try{return new URL(t),e(t,!0)}catch(e){}}throw Error("Please provide a valid domain name")}(e)}},29996:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0
My app info:
const appInfo = {
appName: 'Lokalist Business',
apiDomain: GET_FRONTEND_URL(),
websiteDomain: 'dashboard.lokalist.mobile.app',
apiBasePath: '/api/auth',
websiteBasePath: '/auth',
}
export const GET_FRONTEND_URL = () => {
if (process.env.NEXT_PUBLIC_APP_STAGE === 'production' && process.env.NODE_ENV === 'production') {
return 'https://dashboard.lokalist.nl'
}
if (process.env.NEXT_PUBLIC_APP_STAGE === 'development' && process.env.NODE_ENV === 'production') {
return 'https://staging-dashboard.lokalist.nl'
}
return 'http://localhost:2001'
}
What could it be? The origin is capacitor://localhost
rp_st
06/16/2023, 9:31 AMnkshah2
06/16/2023, 9:33 AMnkshah2
06/16/2023, 9:33 AMhttps://dashboard.lokalist.mobile.app
for examplerobschilder
06/16/2023, 9:33 AMrobschilder
06/16/2023, 9:39 AMrobschilder
06/16/2023, 9:39 AMnkshah2
06/16/2023, 9:40 AMrobschilder
06/16/2023, 9:53 AMrobschilder
06/17/2023, 10:01 AMconst response = (await (await fetch(`https://staging-url.com/api/auth/knock`)).json()) as z.infer<
I am sorry to have bothered you, but the error stated that it was related to Supertokens, which caused the confusion! Haha. Thanks for helping @nkshah2, as friendly as always 🙂nkshah2
06/17/2023, 10:02 AM