aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js/javascript.zig
diff options
context:
space:
mode:
authorGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-09-03 22:47:00 -0700
committerGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-09-03 22:47:00 -0700
commit15b7f9793f0b0121bbf293a0d61340dec820198c (patch)
treef765011bb8237b6e2bf6550297858030ea0e1587 /src/bun.js/javascript.zig
parent04cc1968dbe7947b63b93d800ecc1747dc11eb5f (diff)
downloadbun-15b7f9793f0b0121bbf293a0d61340dec820198c.tar.gz
bun-15b7f9793f0b0121bbf293a0d61340dec820198c.tar.zst
bun-15b7f9793f0b0121bbf293a0d61340dec820198c.zip
[Node API] Fix `napi_module_register`
Diffstat (limited to 'src/bun.js/javascript.zig')
-rw-r--r--src/bun.js/javascript.zig12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/bun.js/javascript.zig b/src/bun.js/javascript.zig
index 54486e38a..5fc440ee7 100644
--- a/src/bun.js/javascript.zig
+++ b/src/bun.js/javascript.zig
@@ -823,6 +823,7 @@ pub const VirtualMachine = struct {
.@"node:string_decoder" => return jsSyntheticModule(.@"node:string_decoder"),
.@"node:module" => return jsSyntheticModule(.@"node:module"),
.@"node:events" => return jsSyntheticModule(.@"node:events"),
+ .@"node:process" => return jsSyntheticModule(.@"node:process"),
.@"node:stream" => {
return ResolvedSource{
.allocator = null,
@@ -851,16 +852,7 @@ pub const VirtualMachine = struct {
.hash = 0,
};
},
- .@"node:process" => {
- return ResolvedSource{
- .allocator = null,
- .source_code = ZigString.init(""),
- .specifier = ZigString.init("node:process"),
- .source_url = ZigString.init("node:process"),
- .hash = 0,
- .tag = ResolvedSource.Tag.@"node:process",
- };
- },
+
.@"node:os" => {
return ResolvedSource{
.allocator = null,