diagnostic: fix cask env var output
With `each`, we don't actually output the processed values. We should therefore be using `filter_map` instead.
This commit is contained in:
parent
62c24bad68
commit
b749cbcffd
@ -1068,7 +1068,7 @@ module Homebrew
|
|||||||
|
|
||||||
locale_variables = ENV.keys.grep(/^(?:LC_\S+|LANG|LANGUAGE)\Z/).sort
|
locale_variables = ENV.keys.grep(/^(?:LC_\S+|LANG|LANGUAGE)\Z/).sort
|
||||||
|
|
||||||
cask_environment_variables = (locale_variables + environment_variables).sort.each do |var|
|
cask_environment_variables = (locale_variables + environment_variables).sort.filter_map do |var|
|
||||||
next unless ENV.key?(var)
|
next unless ENV.key?(var)
|
||||||
|
|
||||||
var = %Q(#{var}="#{ENV.fetch(var)}")
|
var = %Q(#{var}="#{ENV.fetch(var)}")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user