Skip to content

Commit c9364ba

Browse files
committed
remove "retain lines"
1 parent c41fa76 commit c9364ba

File tree

53 files changed

+1827
-2210
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+1827
-2210
lines changed

build/build.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ function processFile (inputLoc, out, replacements) {
4949
})
5050
if (inputLoc.slice(-3) === '.js') {
5151
const transformed = babel.transform(data, {
52-
retainLines: true,
5352
plugins: ['transform-es2015-arrow-functions', 'transform-es2015-block-scoping']
5453
})
5554
data = transformed.code

lib/_stream_duplex.js

Lines changed: 21 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,21 @@
66
'use strict';
77

88
/*<replacement>*/
9+
910
var objectKeys = Object.keys || function (obj) {
1011
var keys = [];
11-
for (var key in obj) {keys.push(key);}
12-
return keys;};
13-
12+
for (var key in obj) {
13+
keys.push(key);
14+
}return keys;
15+
};
1416
/*</replacement>*/
1517

16-
1718
module.exports = Duplex;
1819

1920
/*<replacement>*/
2021
var processNextTick = require('process-nextick-args');
2122
/*</replacement>*/
2223

23-
24-
2524
/*<replacement>*/
2625
var util = require('core-util-is');
2726
util.inherits = require('inherits');
@@ -35,46 +34,42 @@ util.inherits(Duplex, Readable);
3534
var keys = objectKeys(Writable.prototype);
3635
for (var v = 0; v < keys.length; v++) {
3736
var method = keys[v];
38-
if (!Duplex.prototype[method])
39-
Duplex.prototype[method] = Writable.prototype[method];}
40-
37+
if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method];
38+
}
4139

4240
function Duplex(options) {
43-
if (!(this instanceof Duplex))
44-
return new Duplex(options);
41+
if (!(this instanceof Duplex)) return new Duplex(options);
4542

4643
Readable.call(this, options);
4744
Writable.call(this, options);
4845

49-
if (options && options.readable === false)
50-
this.readable = false;
46+
if (options && options.readable === false) this.readable = false;
5147

52-
if (options && options.writable === false)
53-
this.writable = false;
48+
if (options && options.writable === false) this.writable = false;
5449

5550
this.allowHalfOpen = true;
56-
if (options && options.allowHalfOpen === false)
57-
this.allowHalfOpen = false;
58-
59-
this.once('end', onend);}
51+
if (options && options.allowHalfOpen === false) this.allowHalfOpen = false;
6052

53+
this.once('end', onend);
54+
}
6155

6256
// the no-half-open enforcer
6357
function onend() {
6458
// if we allow half-open state, or if the writable side ended,
6559
// then we're ok.
66-
if (this.allowHalfOpen || this._writableState.ended)
67-
return;
60+
if (this.allowHalfOpen || this._writableState.ended) return;
6861

6962
// no more data can be written.
7063
// But allow more writes to happen in this tick.
71-
processNextTick(onEndNT, this);}
72-
64+
processNextTick(onEndNT, this);
65+
}
7366

7467
function onEndNT(self) {
75-
self.end();}
76-
68+
self.end();
69+
}
7770

7871
function forEach(xs, f) {
7972
for (var i = 0, l = xs.length; i < l; i++) {
80-
f(xs[i], i);}}
73+
f(xs[i], i);
74+
}
75+
}

lib/_stream_passthrough.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ util.inherits = require('inherits');
1616
util.inherits(PassThrough, Transform);
1717

1818
function PassThrough(options) {
19-
if (!(this instanceof PassThrough))
20-
return new PassThrough(options);
21-
22-
Transform.call(this, options);}
19+
if (!(this instanceof PassThrough)) return new PassThrough(options);
2320

21+
Transform.call(this, options);
22+
}
2423

2524
PassThrough.prototype._transform = function (chunk, encoding, cb) {
26-
cb(null, chunk);};
25+
cb(null, chunk);
26+
};

0 commit comments

Comments
 (0)