Skip to content

Commit 908abc8

Browse files
committed
fix: incorrect package.json relative path
1 parent 624a56b commit 908abc8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

napi/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ if (!nativeBinding || process.env.NAPI_RS_FORCE_WASI) {
365365

366366
if (!nativeBinding && process.env.SKIP_UNRS_RESOLVER_FALLBACK !== '1') {
367367
try {
368-
nativeBinding = require('napi-postinstall/fallback')(require.resolve('../package.json'), true)
368+
nativeBinding = require('napi-postinstall/fallback')(require.resolve('./package.json'), true)
369369
} catch (err) {
370370
loadErrors.push(err)
371371
}

napi/patch.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ data = data.replace(
1010
`
1111
if (!nativeBinding && process.env.SKIP_UNRS_RESOLVER_FALLBACK !== '1') {
1212
try {
13-
nativeBinding = require('napi-postinstall/fallback')(require.resolve('../package.json'), true)
13+
nativeBinding = require('napi-postinstall/fallback')(require.resolve('./package.json'), true)
1414
} catch (err) {
1515
loadErrors.push(err)
1616
}

0 commit comments

Comments
 (0)