From eb5be9cd34dd9605404cb6cb0cff990356af3cbe Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Mon, 25 Apr 2022 11:11:40 +0200 Subject: [PATCH] [bootloader] Allow skipping an EFI bootloader, too - while here, remove C-style if() --- src/modules/bootloader/main.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/modules/bootloader/main.py b/src/modules/bootloader/main.py index fb8e19ac2..814da37f3 100644 --- a/src/modules/bootloader/main.py +++ b/src/modules/bootloader/main.py @@ -761,8 +761,12 @@ def run(): fw_type = libcalamares.globalstorage.value("firmwareType") - if (libcalamares.globalstorage.value("bootLoader") is None and fw_type != "efi"): - libcalamares.utils.warning( "Non-EFI system, and no bootloader is set." ) + if libcalamares.globalstorage.value("bootLoader") is None: + # Don't want a bootloader, but do log that this has an effect: + if fw_type != "efi": + libcalamares.utils.warning( "Non-EFI system, and no bootloader is set." ) + else: + libcalamares.utils.warning( "EFI system, and no bootloader is set." ) return None partitions = libcalamares.globalstorage.value("partitions")