From 6ba27387bc94472b6ecdd7be46bd24ba9d79db18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tino=20V=C3=A1zquez?= Date: Mon, 10 Oct 2022 18:43:38 +0200 Subject: [PATCH] L #-: Several linting fixes --- src/vmm_mad/remotes/lib/kvm/opennebula_vm.rb | 16 +++++++--------- src/vnm_mad/remotes/lib/vf.rb | 4 ++-- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/src/vmm_mad/remotes/lib/kvm/opennebula_vm.rb b/src/vmm_mad/remotes/lib/kvm/opennebula_vm.rb index 95dc8a7c23..8b438cf705 100644 --- a/src/vmm_mad/remotes/lib/kvm/opennebula_vm.rb +++ b/src/vmm_mad/remotes/lib/kvm/opennebula_vm.rb @@ -222,11 +222,11 @@ module VirtualMachineManagerKVM # NOTE: On detach (as we are manging MAC/VLAN through ip link vf) devices # needs to use format #----------------------------------------------------------------------- - def hostdev_xml(_opts = {}) + def hostdev_xml(defined_opts = {}) opts = { - :force_hostdev => false, - :pci => false - }.merge(_opts) + :force_hostdev => false, + :pci => false + }.merge(defined_opts) prefix_old = @xpath_prefix @xpath_prefix = "TEMPLATE/PCI[ATTACH='YES']/" @@ -258,11 +258,9 @@ module VirtualMachineManagerKVM dev << xputs(' function=%s', 'FUNCTION', :hex => true) dev << '/>' - #Setting Bus address needs to check that a PCI contoller is - #present for Bus 1 - vm_addr = %w[VM_DOMAIN VM_BUS VM_SLOT VM_FUNCTION].all? {|e| - exist? e - } + # Setting Bus address needs to check that a PCI contoller is + # present for Bus 1 + vm_addr = %w[VM_DOMAIN VM_BUS VM_SLOT VM_FUNCTION].all? {|e| exist? e } if vm_addr && opts[:pci] dev << '