feat: enhance CORS handling with public API support and session management

This commit is contained in:
Rotimi Best
2026-05-19 10:24:18 +01:00
parent 917a71ccce
commit 35e780b39d
5 changed files with 67 additions and 15 deletions
@@ -38,6 +38,11 @@ class AppInitApi extends BaseApi {
async setupApp(locals: App.Locals, params: AppSetupParams): Promise<boolean | undefined> {
if (!locals.user) {
if (!params.isOrgSite) {
goto(resolve('/login', {}));
return false;
}
console.log('No user found in locals');
return;
}