Skip to content

Commit

Permalink
Don't call stream TTY methods on streams that are not TTYs (#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
Benjamin Goering authored and sindresorhus committed Jul 17, 2018
1 parent 2cafb1c commit 3c24df2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Expand Up @@ -72,7 +72,7 @@ class Ora {
}

clear() {
if (!this.enabled) {
if (!this.enabled || !this.stream.isTTY) {
return this;
}

Expand Down

0 comments on commit 3c24df2

Please sign in to comment.