Skip to content

Commit

Permalink
fix(compass-web): provide a destroy method in devtools connect polyfill
Browse files Browse the repository at this point in the history
COMPASS-7698 (#5536)

fix(compass-web): provide a destroy method in devtools connect polyfill
  • Loading branch information
gribnoysup committed Mar 5, 2024
1 parent 87a791a commit 6d8869f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ export async function connectMongoClient(
return Promise.resolve('Not Available');
},
oidcPlugin: { logger },
destroy() {
return Promise.resolve();
},
},
};
}
4 changes: 4 additions & 0 deletions packages/compass-web/sandbox/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,10 @@ const App = () => {
setConnectionStringValidationResult,
] = useState<null | string>(null);

(window as any).disconnectCompassWeb = () => {
setOpenCompassWeb(false);
};

const canSubmit =
connectionStringValidationResult === null && connectionString !== '';

Expand Down

0 comments on commit 6d8869f

Please sign in to comment.