1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

more consistent spacing around blocks

This commit is contained in:
Tony Ta 2015-03-16 22:03:44 -07:00
parent 2e361dea00
commit 36e975549c

View file

@ -204,11 +204,11 @@ module Fog
end
def self.uuid
[8,4,4,4,12].map{|i| Fog::Mock.random_hex(i)}.join("-")
[8,4,4,4,12].map { |i| Fog::Mock.random_hex(i) }.join("-")
end
def self.ipv4_address
4.times.map{ Fog::Mock.random_numbers(3) }.join(".")
4.times.map { Fog::Mock.random_numbers(3) }.join(".")
end
def self.ipv6_address
@ -217,13 +217,13 @@ module Fog
def self.keep(hash, *keys)
{}.tap do |kept|
keys.each{|k| kept[k]= hash[k] if hash.key?(k)}
keys.each { |k| kept[k] = hash[k] if hash.key?(k) }
end
end
def self.slice(hash, *keys)
hash.dup.tap do |sliced|
keys.each{|k| sliced.delete(k)}
keys.each { |k| sliced.delete(k) }
end
end