mirror of
https://github.com/actions/github-script.git
synced 2025-12-08 08:06:23 +00:00
Use non-Webpack-require in evaluated scripts
This commit is contained in:
21
dist/index.js
vendored
21
dist/index.js
vendored
@@ -6144,7 +6144,7 @@ async function main() {
|
||||
const github = Object(lib_github.getOctokit)(token, opts);
|
||||
const script = Object(core.getInput)('script', { required: true });
|
||||
// Using property/value shorthand on `require` (e.g. `{require}`) causes compilation errors.
|
||||
const result = await callAsyncFunction({ require: __webpack_require__(875), github, context: lib_github.context, core: core, glob: glob, io: io }, script);
|
||||
const result = await callAsyncFunction({ require: require, github, context: lib_github.context, core: core, glob: glob, io: io }, script);
|
||||
let encoding = Object(core.getInput)('result-encoding');
|
||||
encoding = encoding ? encoding : 'json';
|
||||
let output;
|
||||
@@ -6901,25 +6901,6 @@ function expand(str, isTop) {
|
||||
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 875:
|
||||
/***/ (function(module) {
|
||||
|
||||
function webpackEmptyContext(req) {
|
||||
if (typeof req === 'number' && __webpack_require__.m[req])
|
||||
return __webpack_require__(req);
|
||||
try { return require(req) }
|
||||
catch (e) { if (e.code !== 'MODULE_NOT_FOUND') throw e }
|
||||
var e = new Error("Cannot find module '" + req + "'");
|
||||
e.code = 'MODULE_NOT_FOUND';
|
||||
throw e;
|
||||
}
|
||||
webpackEmptyContext.keys = function() { return []; };
|
||||
webpackEmptyContext.resolve = webpackEmptyContext;
|
||||
module.exports = webpackEmptyContext;
|
||||
webpackEmptyContext.id = 875;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 877:
|
||||
|
||||
Reference in New Issue
Block a user