mirror of
https://github.com/actions/github-script.git
synced 2026-10-09 14:54:17 +03:00
Call resolve, then require
This commit is contained in:
2 files changed
+15
-6
No files matched your search
+8
-3
@@ -10,9 +10,14 @@ export const wrapRequire = new Proxy(__non_webpack_require__, {
|
||||
try {
|
||||
return target.apply(thisArg, [moduleID])
|
||||
} catch (err) {
|
||||
return target.resolve(moduleID, {
|
||||
paths: eval('module').paths.concat(process.cwd())
|
||||
})
|
||||
const modulePath = target.resolve.apply(thisArg, [
|
||||
moduleID,
|
||||
{
|
||||
paths: eval('module').paths.concat(process.cwd())
|
||||
}
|
||||
])
|
||||
|
||||
return target.apply(thisArg, [modulePath])
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
Reference in new issue
Block a user