Skip to content

Commit ace259f

Browse files
committed
remove trailing whitespaces in lib/copystream.js
1 parent d8255c6 commit ace259f

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

lib/copystream.js

+7-7
Original file line numberDiff line numberDiff line change
@@ -33,25 +33,25 @@ CopyFromStream.prototype._handleChunk = function (string, encoding) {
3333
dataChunk = new Buffer(string, encoding);
3434
}
3535
if (this._buffer.length) {
36-
//Buffer.concat is better, but it's missing
36+
//Buffer.concat is better, but it's missing
3737
//in node v0.6.x
38-
tmpBuffer = new Buffer(this._buffer.length + dataChunk.length);
39-
this._buffer.copy(tmpBuffer);
38+
tmpBuffer = new Buffer(this._buffer.length + dataChunk.length);
39+
this._buffer.copy(tmpBuffer);
4040
dataChunk.copy(tmpBuffer, this._buffer.length);
4141
this._buffer = tmpBuffer;
4242
} else {
4343
this._buffer = dataChunk;
4444
}
4545
}
46-
46+
4747
return this._sendIfConnectionReady();
4848
};
4949
CopyFromStream.prototype._sendIfConnectionReady = function () {
5050
var dataSent = false;
5151
if (this._connection) {
5252
dataSent = this._connection.sendCopyFromChunk(this._buffer);
5353
this._buffer = new Buffer(0);
54-
if (this._dataBuffered) {
54+
if (this._dataBuffered) {
5555
this.emit('drain');
5656
}
5757
this._dataBuffered = false;
@@ -84,7 +84,7 @@ CopyFromStream.prototype.end = function (string, encondig) {
8484
};
8585
CopyFromStream.prototype.error = function (error) {
8686
if (this._error || this._closed) {
87-
return false;
87+
return false;
8888
}
8989
this._error = true;
9090
this.emit('error', error);
@@ -171,7 +171,7 @@ CopyToStream.prototype.resume = function () {
171171
this._outputDataChunk();
172172
if (this._error) {
173173
return this.emit('error', this._error);
174-
}
174+
}
175175
if (this._finished) {
176176
return this.emit('end');
177177
}

0 commit comments

Comments
 (0)