Skip to content

Commit

Permalink
Merge pull request #16824 from d-m-u/fixing_openstack_cloud_network_call
Browse files Browse the repository at this point in the history
Fix call to get_targets_for_source to be correct scope name
  • Loading branch information
gmcculloug authored Jan 19, 2018
2 parents bd1416e + 3eb218e commit f5f9a83
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def allowed_cloud_subnets(_options = {})

def allowed_cloud_networks(_options = {})
return {} unless (src = provider_or_tenant_object)
targets = get_targets_for_source(src, :cloud_filter, CloudNetwork, 'cloud_networks')
targets = get_targets_for_source(src, :cloud_filter, CloudNetwork, 'all_cloud_networks')
allowed_ci(:cloud_network, [:availability_zone], targets.map(&:id))
end

Expand Down Expand Up @@ -95,7 +95,7 @@ def availability_zone_to_cloud_network(src)
hash[cn.id] = cn.name
end
else
load_ar_obj(src[:ems]).cloud_subnets.collect(&:cloud_network).each_with_object({}) do |cn, hash|
load_ar_obj(src[:ems]).all_cloud_networks.each_with_object({}) do |cn, hash|
hash[cn.id] = cn.name
end
end
Expand Down

0 comments on commit f5f9a83

Please sign in to comment.