From 1b4d3f1e3ccc8968910195d055d37bee9a8fa48b Mon Sep 17 00:00:00 2001 From: Scott Seago Date: Tue, 10 Oct 2017 10:23:33 -0400 Subject: [PATCH] bug 1494442: fix attach/detach disks automate methods Fix for bug 1494442 - symbol conversion error while detaching disks from an openstack instance https://bugzilla.redhat.com/show_bug.cgi?id=1494442 --- .../manageiq/providers/openstack/cloud_manager.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/models/manageiq/providers/openstack/cloud_manager.rb b/app/models/manageiq/providers/openstack/cloud_manager.rb index 2fd8eaafd..df0187c87 100644 --- a/app/models/manageiq/providers/openstack/cloud_manager.rb +++ b/app/models/manageiq/providers/openstack/cloud_manager.rb @@ -342,13 +342,13 @@ def vm_delete_evm_snapshot(vm, image_id) raise end - def vm_attach_volume(vm, volume_id, device = nil) - volume = find_by_id_filtered(CloudVolume, volume_id) - volume.raw_attach_volume(vm.ems_ref, device) + def vm_attach_volume(vm, options) + volume = CloudVolume.find_by(:id => options[:volume_id]) + volume.raw_attach_volume(vm.ems_ref, options[:device]) end - def vm_detach_volume(vm, volume_id) - volume = find_by_id_filtered(CloudVolume, volume_id) + def vm_detach_volume(vm, options) + volume = CloudVolume.find_by(:id => options[:volume_id]) volume.raw_detach_volume(vm.ems_ref) end