From 1498085ff908f401822ebeca09f688c616b2da72 Mon Sep 17 00:00:00 2001 From: Cole Robinson Date: Thu, 3 Feb 2022 12:18:40 -0500 Subject: [PATCH] domcapabilities: Remove redundant check get_enum() will always succeed, so the first check is redundant Signed-off-by: Cole Robinson --- virtinst/domcapabilities.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/virtinst/domcapabilities.py b/virtinst/domcapabilities.py index 0c126d0e..cfee07f3 100644 --- a/virtinst/domcapabilities.py +++ b/virtinst/domcapabilities.py @@ -260,8 +260,7 @@ class DomainCapabilities(XMLBuilder): """ Return True if libvirt advertises support for UEFI loader """ - return ("readonly" in self.os.loader.enum_names() and - "yes" in self.os.loader.get_enum("readonly").get_values()) + return "yes" in self.os.loader.get_enum("readonly").get_values() def supports_firmware_efi(self): return "efi" in self.os.get_enum("firmware").get_values()