diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash index 45ec47f2b..e3918c87e 100644 --- a/contrib/completion/git-completion.bash +++ b/contrib/completion/git-completion.bash @@ -2415,8 +2415,8 @@ _git_stash () show,--*|branch,--*) ;; branch,*) - if [ $cword -eq 3 ]; then - __gitcomp_nl "$(__git_refs)"; + if [ $cword -eq 3 ]; then + __gitcomp_nl "$(__git_refs)"; else __gitcomp_nl "$(git --git-dir="$(__gitdir)" stash list \ | sed -n -e 's/:.*//p')"