From 7c2216a4088c5d6b0146567dca49d24030265011 Mon Sep 17 00:00:00 2001 From: hotpocket Date: Mon, 5 Feb 2018 21:58:07 -0800 Subject: [PATCH] prefer if/else. magicmonty/bash-git-prompt/pull/370 --- gitprompt.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gitprompt.sh b/gitprompt.sh index faefdc1..74f39a2 100755 --- a/gitprompt.sh +++ b/gitprompt.sh @@ -303,9 +303,9 @@ function setLastCommandState() { function we_are_on_repo() { if [[ -e "$(git rev-parse --git-dir 2> /dev/null)" ]]; then echo 1 - return + else + echo 0 fi - echo 0 } function update_old_git_prompt() {