mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
[google|compute] disk model: get_object fix for Ruby 1.8
This commit is contained in:
parent
044ca68e74
commit
0c07637cb8
1 changed files with 2 additions and 1 deletions
|
@ -59,13 +59,14 @@ module Fog
|
|||
|
||||
def get_object(writable=true, boot=false, device_name=nil)
|
||||
mode = writable ? 'READ_WRITE' : 'READ_ONLY'
|
||||
return {
|
||||
value = {
|
||||
'boot' => boot,
|
||||
'source' => self_link,
|
||||
'mode' => mode,
|
||||
'deviceName' => device_name,
|
||||
'type' => 'PERSISTENT'
|
||||
}.select { |k, v| !v.nil? }
|
||||
return Hash[value]
|
||||
end
|
||||
|
||||
def get_as_boot_disk(writable=true)
|
||||
|
|
Loading…
Reference in a new issue