diff --git a/grubby-bls b/grubby-bls index 6e0acb6..5ac7c6a 100755 --- a/grubby-bls +++ b/grubby-bls @@ -127,13 +127,13 @@ get_default_index() { # GRUB2 and zipl use different fields to set the default entry if [[ $bootloader = "grub2" ]]; then - title="$default" + id="$default" else version="$default" fi for i in ${!bls_file[@]}; do - if [[ $title = ${bls_title[$i]} || $version = ${bls_version[$i]} || + if [[ $title = ${bls_title[$i]} || $id = ${bls_id[$i]} || $i -eq $index ]]; then echo $i return