lib/fog/azurerm/models/network/network_security_rule.rb in fog-azure-rm-0.1.0 vs lib/fog/azurerm/models/network/network_security_rule.rb in fog-azure-rm-0.1.1

- old
+ new

@@ -19,11 +19,11 @@ def self.parse(nsr) hash = {} hash['id'] = nsr.id hash['name'] = nsr.name - hash['resource_group'] = get_resource_from_resource_id(nsr.id, RESOURCE_GROUP_NAME) + hash['resource_group'] = get_resource_group_from_id(nsr.id) hash['network_security_group_name'] = get_resource_from_resource_id(nsr.id, RESOURCE_NAME) hash['description'] = nsr.description hash['protocol'] = nsr.protocol hash['source_port_range'] = nsr.source_port_range hash['destination_port_range'] = nsr.destination_port_range @@ -35,15 +35,14 @@ hash end def save requires :name, :network_security_group_name, :resource_group, :protocol, :source_port_range, :destination_port_range, :source_address_prefix, :destination_address_prefix, :access, :priority, :direction - security_rule_params = get_security_rule_params network_security_rule = service.create_or_update_network_security_rule(security_rule_params) - merge_attributes(NetworkSecurityRule.parse(network_security_rule)) + merge_attributes(Fog::Network::AzureRM::NetworkSecurityRule.parse(network_security_rule)) end - def get_security_rule_params + def security_rule_params { name: name, resource_group: resource_group, protocol: protocol, network_security_group_name: network_security_group_name,