lib/providers/hpcloud/compute.rb in lorj-1.0.1 vs lib/providers/hpcloud/compute.rb in lorj-1.0.2
- old
+ new
@@ -52,13 +52,13 @@
# CloudProcess used a simplified way to manage IPs.
# Following is the translation to get the public IPs for the server
result = []
addresses = oComputeConnect.addresses.all
- addresses.each do | oElem |
+ addresses.each do |oElem|
is_found = true
- sQuery.each do | key, value |
+ sQuery.each do |key, value|
if !oElem.attributes.key?(key) || oElem.attributes[key] != value
is_found = false
break
end
end
@@ -74,10 +74,10 @@
end
addresses = oComputeConnect.addresses.all
address = nil
# Search for an available IP
- addresses.each do | oElem |
+ addresses.each do |oElem|
if oElem.fixed_ip.nil?
address = oElem
break
end
end