lib/fog/azurerm/models/compute/availability_sets.rb in fog-azure-rm-0.0.1 vs lib/fog/azurerm/models/compute/availability_sets.rb in fog-azure-rm-0.0.2

- old
+ new

@@ -14,15 +14,11 @@ requires :resource_group list_of_availability_sets = service.list_availability_sets(resource_group) unless list_of_availability_sets.nil? list_of_availability_sets.each do |account| - hash = {} - account.instance_variables.each do |var| - hash[var.to_s.delete('@')] = account.instance_variable_get(var) - end - hash['resource_group'] = resource_group - accounts << hash + parse_response = Fog::Compute::AzureRM::AvailabilitySet.parse(account) + accounts << parse_response end end load(accounts) end