[bootloader] Allow skipping an EFI bootloader, too

- while here, remove C-style if()
This commit is contained in:
Adriaan de Groot 2022-04-25 11:11:40 +02:00
parent cab4be1bd0
commit eb5be9cd34

View File

@ -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")