diff --git a/build.json b/build.json index ddcf5cfb..5dbfd5f5 100644 --- a/build.json +++ b/build.json @@ -1 +1 @@ -{"owner":"technote-space","repo":"get-diff-action","sha":"b958f526076e9924cb13343f1b5da165827a5043","ref":"refs/tags/test/v6.1.2.3551960194","tagName":"test/v6.1.2.3551960194","branch":"gh-actions","tags":["test/v6.1.2.3551960194","test/v6.1.2","test/v6.1","test/v6"],"updated_at":"2022-11-26T03:09:53.770Z"} \ No newline at end of file +{"owner":"technote-space","repo":"get-diff-action","sha":"191d7c52f0e9b31a18deddf081b131c46ea6f8d2","ref":"refs/tags/test/v6.1.2.3570657478","tagName":"test/v6.1.2.3570657478","branch":"gh-actions","tags":["test/v6.1.2.3570657478","test/v6.1.2","test/v6.1","test/v6"],"updated_at":"2022-11-29T03:12:16.164Z"} \ No newline at end of file diff --git a/lib/main.js b/lib/main.js index 7185edbd..79cf2dc4 100644 --- a/lib/main.js +++ b/lib/main.js @@ -25,7 +25,13 @@ function getDefaultExportFromCjs (x) { function getAugmentedNamespace(n) { var f = n.default; if (typeof f == "function") { - var a = function () { + var a = function a () { + if (this instanceof a) { + var args = [null]; + args.push.apply(args, arguments); + var Ctor = Function.bind.apply(f, args); + return new Ctor(); + } return f.apply(this, arguments); }; a.prototype = f.prototype;