Skip to content

Commit 467ecb3

Browse files
committed
fix lost default volume_type after creating LVM volume
1 parent 73feb82 commit 467ecb3

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

lib/fog/libvirt/models/compute/volume.rb

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,13 @@ def wipe
5353
service.volume_action key, :wipe
5454
end
5555

56+
def reload
57+
super
58+
59+
# Restore lost defaults
60+
self.format_type ||= defaults[:format_type]
61+
end
62+
5663
# Clones this volume to the name provided
5764
def clone(name)
5865
new_volume = self.dup

0 commit comments

Comments
 (0)