We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
readStream.setRawMode()
this
1 parent 2b29df7 commit 1f4d4c0Copy full SHA for 1f4d4c0
doc/api/tty.md
@@ -64,6 +64,7 @@ added: v0.7.7
64
raw device. If `false`, configures the `tty.ReadStream` to operate in its
65
default mode. The `readStream.isRaw` property will be set to the resulting
66
mode.
67
+* Returns: {this} - the read stream instance.
68
69
Allows configuration of `tty.ReadStream` so that it operates as a raw device.
70
lib/tty.js
@@ -71,9 +71,10 @@ ReadStream.prototype.setRawMode = function(flag) {
71
const err = this._handle.setRawMode(flag);
72
if (err) {
73
this.emit('error', errors.errnoException(err, 'setRawMode'));
74
- return;
+ return this;
75
}
76
this.isRaw = flag;
77
78
};
79
80
function WriteStream(fd) {
0 commit comments