From 378b910af695ab641c3b448339d8d79b7a15acd7 Mon Sep 17 00:00:00 2001 From: John Koelndorfer Date: Tue, 1 Sep 2015 18:55:14 -0500 Subject: [PATCH] Use defined to check if ICON_USER_VARIABLE is defined. --- powerlevel9k.zsh-theme | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/powerlevel9k.zsh-theme b/powerlevel9k.zsh-theme index d5f77148..3b89b1df 100644 --- a/powerlevel9k.zsh-theme +++ b/powerlevel9k.zsh-theme @@ -60,7 +60,7 @@ function print_icon() { local icon_name=$1 local ICON_USER_VARIABLE=POWERLEVEL9K_${icon_name} local USER_ICON=${(P)ICON_USER_VARIABLE} - if [[ -n "$USER_ICON" ]]; then + if defined "$ICON_USER_VARIABLE"; then echo -n $USER_ICON else echo -n ${icons[$icon_name]}