Skip to content

Commit

Permalink
Update ProcessContainerFork.js
Browse files Browse the repository at this point in the history
This commit fixes issue Unitech#4839
  • Loading branch information
ox-harris authored and remz committed Dec 29, 2020
1 parent 864b084 commit c487053
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/ProcessContainerFork.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
* Use of this source code is governed by a license that
* can be found in the LICENSE file.
*/
var url = require('url');
// Inject custom modules
var ProcessUtils = require('./ProcessUtils')
ProcessUtils.injectModules()
Expand All @@ -26,7 +27,7 @@ if (process.connected &&
// Require the real application
if (process.env.pm_exec_path) {
if (ProcessUtils.isESModule(process.env.pm_exec_path) === true) {
import(process.env.pm_exec_path);
import(url.pathToFileURL(process.env.pm_exec_path));
}
else
require('module')._load(process.env.pm_exec_path, null, true);
Expand Down

0 comments on commit c487053

Please sign in to comment.