From 2a909b3bcfc027366e33a4d4a933237fa7c61497 Mon Sep 17 00:00:00 2001 From: Knut Ahlers Date: Tue, 5 Mar 2019 15:23:27 +0100 Subject: [PATCH] Fix: Don't crash on unset variable Signed-off-by: Knut Ahlers --- .config/i3blocks/wifi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.config/i3blocks/wifi b/.config/i3blocks/wifi index 6013735..9852cb5 100755 --- a/.config/i3blocks/wifi +++ b/.config/i3blocks/wifi @@ -19,4 +19,4 @@ network=$(iwgetid -r) printf "\uf9a1 %s (%s)" ${network} ${ip} # On click copy IP -[ -n "${BLOCK_BUTTON}" ] && echo -n "${ip}" | tr -d '\n' | xclip -selection c +[ -n "${BLOCK_BUTTON:-}" ] && echo -n "${ip}" | tr -d '\n' | xclip -selection c