@@ -5,7 +5,6 @@ var browserify = require('browserify');
55var minify = require ( 'minify-stream' ) ;
66var derequire = require ( 'derequire' ) ;
77var through = require ( 'through2' ) ;
8- var exorcist = require ( 'exorcist' ) ;
98
109var strictD3 = require ( './strict_d3' ) ;
1110
@@ -35,8 +34,7 @@ module.exports = function _bundle(pathToIndex, pathToBundle, opts, cb) {
3534
3635 var browserifyOpts = { } ;
3736 browserifyOpts . standalone = opts . standalone ;
38- var sourceMap = opts . pathToSourceMap ;
39- browserifyOpts . debug = opts . debug || ! ! sourceMap ;
37+ browserifyOpts . debug = opts . debug ;
4038
4139 if ( opts . noCompress ) {
4240 browserifyOpts . ignoreTransform = './tasks/compress_attributes.js' ;
@@ -70,33 +68,17 @@ module.exports = function _bundle(pathToIndex, pathToBundle, opts, cb) {
7068 ascii_only : true
7169 } ,
7270
73- sourceMap : sourceMap ? {
74- includeSources : true ,
75- root : '/' ,
76- filename : path . basename ( pathToMinBundle )
77- } : false
71+ sourceMap : false
7872 } ;
7973
80- if ( sourceMap ) {
81- bundleStream
82- . pipe ( applyDerequire ( ) )
83- . pipe ( minify ( minifyOpts ) )
84- . pipe ( exorcist ( sourceMap ) )
85- . pipe ( fs . createWriteStream ( pathToMinBundle ) )
86- . on ( 'finish' , function ( ) {
87- logger ( pathToMinBundle ) ;
88- done ( ) ;
89- } ) ;
90- } else {
91- bundleStream
92- . pipe ( applyDerequire ( ) )
93- . pipe ( minify ( minifyOpts ) )
94- . pipe ( fs . createWriteStream ( pathToMinBundle ) )
95- . on ( 'finish' , function ( ) {
96- logger ( pathToMinBundle ) ;
97- done ( ) ;
98- } ) ;
99- }
74+ bundleStream
75+ . pipe ( applyDerequire ( ) )
76+ . pipe ( minify ( minifyOpts ) )
77+ . pipe ( fs . createWriteStream ( pathToMinBundle ) )
78+ . on ( 'finish' , function ( ) {
79+ logger ( pathToMinBundle ) ;
80+ done ( ) ;
81+ } ) ;
10082 }
10183
10284 if ( pathToBundle ) {
0 commit comments