I now get a null pointer exception
mappings: inputSourceMap.mappings,
This is because my prod build is not generating source maps and somehow the inputSourceMap is null (I am not setting it). The following code checks for undefined but not null.
If I change the following
https://github.com/TypeStrong/ts-loader/blob/9315855cd6f87883b137fc762da02f99a7842f46/src/index.ts#L152C3-L152C3
if (sourceMap === undefined || inputSourceMap === undefined) { callback(null, output, sourceMap); return; }
to
if (!sourceMap || !inputSourceMap) { callback(null, output, sourceMap); return; }
everything works as expected.
I now get a null pointer exception
mappings: inputSourceMap.mappings,
This is because my prod build is not generating source maps and somehow the inputSourceMap is null (I am not setting it). The following code checks for undefined but not null.
If I change the following
https://github.com/TypeStrong/ts-loader/blob/9315855cd6f87883b137fc762da02f99a7842f46/src/index.ts#L152C3-L152C3
if (sourceMap === undefined || inputSourceMap === undefined) { callback(null, output, sourceMap); return; }to
if (!sourceMap || !inputSourceMap) { callback(null, output, sourceMap); return; }everything works as expected.