From 4466d0817421053b3c9548054622959c854aabf0 Mon Sep 17 00:00:00 2001 From: bullno1 Date: Sun, 17 Aug 2014 23:20:31 +0800 Subject: [PATCH] Normalize conditional expressions --- plugins/zbell/zbell.plugin.zsh | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/plugins/zbell/zbell.plugin.zsh b/plugins/zbell/zbell.plugin.zsh index 00ac2f76..2fa7e14c 100644 --- a/plugins/zbell/zbell.plugin.zsh +++ b/plugins/zbell/zbell.plugin.zsh @@ -50,13 +50,9 @@ zbell_end() { zbell_lastcmd_tmp="$zbell_lastcmd" regexp-replace zbell_lastcmd_tmp '^sudo ' '' - if [[ $zbell_last_timestamp == $zbell_timestamp ]]; then - return - fi + [[ $zbell_last_timestamp == $zbell_timestamp ]] && return - if [[ $zbell_lastcmd_tmp == "" ]]; then - return; - fi + [[ $zbell_lastcmd_tmp == "" ]] && return zbell_last_timestamp=$zbell_timestamp