We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ca8be39 commit fbe36a7Copy full SHA for fbe36a7
lib/fs.js
@@ -1027,8 +1027,7 @@ WriteStream.prototype.flush = function() {
1027
1028
WriteStream.prototype.write = function(data) {
1029
if (!this.writable) {
1030
- this.emit("error", new Error('stream not writable'));
1031
- return false;
+ throw new Error('stream not writable');
1032
}
1033
1034
this.drainable = true;
lib/tty_win32.js
@@ -99,8 +99,7 @@ WriteStream.prototype.isTTY = true;
99
100
WriteStream.prototype.write = function(data, encoding) {
101
102
103
104
105
106
if (Buffer.isBuffer(data)) {
0 commit comments