Skip to content

Commit 9173bbe

Browse files
authored
Update packages/adapter-cloudflare-workers/index.js
1 parent 277e9b6 commit 9173bbe

File tree

1 file changed

+2
-1
lines changed
  • packages/adapter-cloudflare-workers

1 file changed

+2
-1
lines changed

packages/adapter-cloudflare-workers/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,8 @@ export default function ({ config = 'wrangler.toml', platformProxy = {} } = {})
150150
},
151151

152152
emulate() {
153-
// we want to invoke `getPlatformProxy` only once and await it only when it is accessed
153+
// we want to invoke `getPlatformProxy` only once, but await it only when it is accessed.
154+
// If we would await it here, it would hang indefinitely because the platform proxy only resolves once a request happens
154155
const getting_platform = (async () => {
155156
const proxy = await getPlatformProxy(platformProxy);
156157
const platform = /** @type {App.Platform} */ ({

0 commit comments

Comments
 (0)