Skip to content
This repository was archived by the owner on Oct 9, 2020. It is now read-only.

Commit f018a60

Browse files
committed
fix case for without source maps
1 parent e6bd7c5 commit f018a60

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

compilers/esm.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,8 @@ exports.compile = function(load, opts, loader) {
118118
output.code = output.code.replace(/(\s|^)System\.register\(/, '$1' + opts.systemGlobal + '.register(');
119119

120120
// for some reason Babel isn't respecting sourceFileName...
121-
output.map.sources[0] = load.path;
121+
if (output.map)
122+
output.map.sources[0] = load.path;
122123

123124
return Promise.resolve({
124125
source: output.code,

0 commit comments

Comments
 (0)