From 10272b9aa485de152e5d2e219e9dc874fdaffeed Mon Sep 17 00:00:00 2001 From: Simon Gomizelj Date: Tue, 6 Dec 2011 12:34:53 -0500 Subject: [PATCH] Better theme failing-to-load support. --- lib/theming.zsh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/theming.zsh b/lib/theming.zsh index a890beacc..9ed58c701 100644 --- a/lib/theming.zsh +++ b/lib/theming.zsh @@ -1,7 +1,10 @@ set_theme() { local themes themes=({$OMZ,$ZSH}/themes/$1.zsh-theme(N)) - source $themes[1] || omz_log_msg "theme: $1 was not found. falling back to default." && source $ZSH/themes/default.zsh-theme + if ! source $themes[1]; then + omz_log_msg "theme: $1 was not found. falling back to default." + source $ZSH/themes/default.zsh-theme + fi } random_theme() {