fix(frontend): Always return user is authed if mode is oss (#4733)

This commit is contained in:
sp.wack
2024-11-04 18:24:23 +02:00
committed by GitHub
parent 1638968509
commit f0af90bff3
2 changed files with 3 additions and 1 deletions

View File

@@ -55,7 +55,7 @@ export const clientLoader = async ({ request }: ClientLoaderFunctionArgs) => {
posthog.opt_in_capturing();
}
let isAuthed: boolean = false;
let isAuthed = false;
let githubAuthUrl: string | null = null;
try {

View File

@@ -1,6 +1,8 @@
import OpenHands from "#/api/open-hands";
export const userIsAuthenticated = async () => {
if (window.__APP_MODE__ === "oss") return true;
try {
await OpenHands.authenticate();
return true;