1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Import default export if node is a transpiled es module

This commit is contained in:
Dominik Schmidt 2022-06-14 22:54:00 +02:00 committed by GitHub
parent 8762d0e164
commit 326f346936
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -359,6 +359,7 @@ function loadNodeSet(node) {
try {
var loadPromise = null;
var r = require(node.file);
r = r.__esModule ? r.default : r
if (typeof r === "function") {
var red = registryUtil.createNodeApi(node);