From 779eb259db27649c52a30d3f1eeb2f95dddcf9a1 Mon Sep 17 00:00:00 2001 From: qgarnier Date: Wed, 6 Dec 2017 14:05:59 +0100 Subject: [PATCH] enhance xtermio --- storage/emc/xtremio/restapi/custom/xtremioapi.pm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/storage/emc/xtremio/restapi/custom/xtremioapi.pm b/storage/emc/xtremio/restapi/custom/xtremioapi.pm index 0fd5c04cf..c1389aec3 100644 --- a/storage/emc/xtremio/restapi/custom/xtremioapi.pm +++ b/storage/emc/xtremio/restapi/custom/xtremioapi.pm @@ -204,8 +204,10 @@ sub get_details_lookup_clusters { # "error_code": 400 #} # - my $clusters = $self->cache_clusters(); - foreach my $cluster_name (keys %$clusters) { + if (!defined($self->{cache_clusters})) { + $self->{cache_clusters} = $self->cache_clusters(); + } + foreach my $cluster_name (keys %{$self->{cache_clusters}}) { my $url = $options{url} . $options{append} . 'cluster-name=' . $cluster_name; my $decoded = $self->get_details_data(url => $url); return $decoded if (!defined($decoded->{error_code}));