Skip to content

Commit 0fee5c6

Browse files
petebacondarwinvicb
andcommitted
Apply suggestions from code review
Co-authored-by: Victor Berchet <victor@suumit.com>
1 parent 28e1aa7 commit 0fee5c6

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

packages/vite-plugin-cloudflare/playground/node-compat/worker-process/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ export default {
88
} satisfies ExportedHandler;
99

1010
function testProcessBehaviour() {
11+
// workerd does not implement `process.stderr`, it comes from unenv.
1112
assert(stderr, "process.stderr was not polyfilled early enough!");
1213
const originalProcess = process;
1314
try {

packages/vite-plugin-cloudflare/src/node-js-compat.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ const injectsByModule = new Map<
7878
{ injectedName: string; exportName: string; importName: string }[]
7979
>();
8080
/**
81-
* Map of virtual module (prefixed by `\0_nodejs_global_inject-`) to injectable module id,
81+
* Map of virtual module (prefixed by `virtualModulePrefix`) to injectable module id,
8282
* which then maps via `injectsByModule` to the global code to be injected.
8383
*/
8484
const virtualModulePathToSpecifier = new Map<string, string>();

0 commit comments

Comments
 (0)