Early return in Tty#color?
for nil @stream
This commit is contained in:
parent
599616e8e0
commit
f3a68b616c
@ -161,8 +161,9 @@ module Tty
|
|||||||
|
|
||||||
return false if Homebrew::EnvConfig.no_color?
|
return false if Homebrew::EnvConfig.no_color?
|
||||||
return true if Homebrew::EnvConfig.color?
|
return true if Homebrew::EnvConfig.color?
|
||||||
|
return false if @stream.blank?
|
||||||
|
|
||||||
!!@stream&.tty?
|
@stream.tty?
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user