Skip to content

Commit

Permalink
fix: post message added undefined check
Browse files Browse the repository at this point in the history
  • Loading branch information
varun2948 committed Mar 28, 2024
1 parent bb3e2a0 commit 684197e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/frontend/src/views/Authorized.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function Authorized() {
// First case: authCode is passed
// return to get user details
if (authCode !== null) {
window.opener.postMessage({ authCode, state }, '*');
window?.opener?.postMessage({ authCode, state }, '*');
window.close();
return;
}
Expand Down
2 changes: 1 addition & 1 deletion src/frontend/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export default defineConfig(({ mode }) => {
devOptions: {
enabled: true,
},
selfDestroying: true,
selfDestroying: false,
}),
],
server: {
Expand Down

0 comments on commit 684197e

Please sign in to comment.