Skip to content

Commit a10e446

Browse files
committed
fix race condition
1 parent 40ecc8e commit a10e446

File tree

1 file changed

+4
-1
lines changed
  • src/lib/client/adapters/webcontainer

1 file changed

+4
-1
lines changed

src/lib/client/adapters/webcontainer/index.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,10 @@ async function _create(stubs) {
5252
throw new Error('WebContainers are not supported by Safari');
5353
}
5454

55-
const base = await new Promise(async (fulfil, reject) => {
55+
/** @type {string} */
56+
let base;
57+
58+
base = await new Promise(async (fulfil, reject) => {
5659
/** @type {any} */
5760
let timeout;
5861
function reset_timeout() {

0 commit comments

Comments
 (0)