1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-23 22:50:09 +03:00

B #5419: Protected info_all method does respond_to? in Ruby 1.9

(cherry picked from commit 861b292f16294a6f178666e66e67df2637e75464)
This commit is contained in:
Jaime Melis 2017-09-28 17:01:09 +02:00
parent 1166485a7f
commit b502c32a64

View File

@ -34,9 +34,11 @@ class VIHelper
def self.one_pool(the_class, exit_if_fail = true)
item = the_class.new(client)
if item.respond_to?(:info_all)
rc = nil
begin
rc = item.info_all
else
rescue
rc = item.info
end