Skip to content
This repository was archived by the owner on Sep 19, 2025. It is now read-only.

Commit a89bfe8

Browse files
Remove the workaround for absolute paths from the gulp plugin
1 parent f6defa0 commit a89bfe8

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

lib/gulp/concat-to-json.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,7 @@ module.exports = function(files) {
4848
var jsonFiles = [];
4949
for (var i = 0; i < files.length; i++) {
5050
jsonFiles.push(
51-
json_file(files[i].contents.toString(),
52-
'/' + path.relative(process.cwd(), files[i].path),
51+
json_file(files[i].contents.toString(), files[i].relative || path.relative(process.cwd(), files[i].path),
5352
files[i].sourceMap ? JSON.stringify(files[i].sourceMap) : undefined));
5453
}
5554

lib/gulp/index.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -196,11 +196,6 @@ module.exports = function(initOptions) {
196196

197197
for (var i = 0; i < outputFiles.length; i++) {
198198
if (outputFiles[i].sourceMap) {
199-
if (outputFiles[i].sourceMap.sources) {
200-
outputFiles[i].sourceMap.sources = outputFiles[i].sourceMap.sources.map(function(sourcePath) {
201-
return path.isAbsolute(sourcePath[0]) ? sourcePath.substr(1) : sourcePath;
202-
});
203-
}
204199
applySourceMap(outputFiles[i], outputFiles[i].sourceMap);
205200
}
206201
this.push(outputFiles[i]);

0 commit comments

Comments
 (0)