diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/leap_cli/config/manager.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/leap_cli/config/manager.rb b/lib/leap_cli/config/manager.rb index 9b452f3..2013217 100644 --- a/lib/leap_cli/config/manager.rb +++ b/lib/leap_cli/config/manager.rb @@ -50,7 +50,9 @@ module LeapCli # the returned array includes nil (for the default environment) # def environment_names - @environment_names ||= [nil] + env.tags.collect {|name, tag| tag['environment']}.compact + @environment_names ||= begin + [nil] + (env.tags.field('environment') + nodes.field('environment')).compact.uniq + end end # |