lib/eco/api/session/config.rb in eco-helpers-2.5.2 vs lib/eco/api/session/config.rb in eco-helpers-2.5.3
- old
+ new
@@ -241,11 +241,15 @@
end
# It obtains the first of the live tagtree in the org
# @note it requires graphql connection configuration parameters
# @return [Eco::API::Organization::TagTree]
- def live_tree(enviro: nil)
- @live_tree ||= tagtree_config.live_tree(enviro: enviro)
+ def live_tree(id: nil, enviro: nil, **kargs, &block)
+ if id
+ tagtree_config.live_tree_get(id: id, enviro: enviro, **kargs, &block)
+ else
+ tagtree_config.live_tree(enviro: enviro, **kargs, &block)
+ end
end
# @return [Eco::API::Organization::PolicyGroups]
def policy_groups
return @policy_groups if instance_variable_defined?(:@policy_groups)