Skip to content

Commit 6ba3c3f

Browse files
committed
Fix
1 parent 67b3efa commit 6ba3c3f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

web/pages/_app.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,12 @@ function MyApp({Component, pageProps}: AppProps<PageProps>) {
6767
useEffect(() => {
6868
async function oauthRedirect(event: any) {
6969
console.log('Received oauthRedirect event:', event);
70-
const detail = event
70+
const detail = event.data
7171
console.log('OAuth data:', detail);
72+
if (!detail) {
73+
console.error('No detail found in event');
74+
return;
75+
}
7276
const url = new URL(detail);
7377

7478
const code = url.searchParams.get('code');

0 commit comments

Comments
 (0)