Skip to content

Commit f0d0226

Browse files
authored
remove process.version override now that unenv#493 is merged (#1218)
1 parent ac28b08 commit f0d0226

2 files changed

Lines changed: 7 additions & 6 deletions

File tree

.changeset/every-animals-poke.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
"@opennextjs/cloudflare": patch
3+
---
4+
5+
remove `process.version` override
6+
7+
Remove process.version / process.versions.node overrides now that [unjs/unenv#493](https://github.com/unjs/unenv/pull/493) is merged and shipped in [unenv@2.0.0-rc.16](https://github.com/unjs/unenv/releases/tag/v2.0.0-rc.16) (project uses 2.0.0-rc.24)

packages/cloudflare/src/cli/templates/init.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,6 @@ function init(request: Request, env: CloudflareEnv) {
5353
}
5454

5555
function initRuntime() {
56-
// Some packages rely on `process.version` and `process.versions.node` (i.e. Jose@4)
57-
// TODO: Remove when https://github.com/unjs/unenv/pull/493 is merged
58-
Object.assign(process, { version: process.version || "v22.14.0" });
59-
// @ts-expect-error Node type does not match workerd
60-
Object.assign(process.versions, { node: "22.14.0", ...process.versions });
61-
6256
globalThis.__dirname ??= "";
6357
globalThis.__filename ??= "";
6458
// Some packages rely on `import.meta.url` but it is undefined in workerd

0 commit comments

Comments
 (0)