mirror of
https://github.com/dcarrillo/prezto.git
synced 2024-12-22 17:28:01 +00:00
Check for empty values in $key_info properly
This commit is contained in:
parent
bc8533c30e
commit
b1b5af23b6
@ -95,9 +95,10 @@ key_info=(
|
|||||||
)
|
)
|
||||||
|
|
||||||
# Do not bind any keys if there are empty values in $key_info.
|
# Do not bind any keys if there are empty values in $key_info.
|
||||||
for key in "$key_info[@]"; do
|
for key in "${(k)key_info[@]}"; do
|
||||||
if [[ -z "$key" ]]; then
|
if [[ -z "$key_info[$key]" ]]; then
|
||||||
print "prezto: one or more keys are non-bindable" >&2
|
print "prezto: one or more keys are non-bindable" >&2
|
||||||
|
unset key{,_info}
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user