[prompt] change unset variable test

The old test, [[ ${var} ]] tests for unset AND zero-length strings.

Checking for zero length strings probably isn't that important. It is
enough to ensure that the variable is set.

Closes #18
This commit is contained in:
Matt Hamilton 2016-01-08 09:16:22 -05:00
parent 7020eead86
commit d13614e3bb
1 changed files with 1 additions and 1 deletions

View File

@ -2,7 +2,7 @@
# load user-defined prompt
#
if [[ ! ${TERM} == (linux|*bsd*|dumb) ]] && [[ ${zprompt_theme} ]]; then
if [[ ! ${TERM} == (linux|*bsd*|dumb) ]] && (( ${+zprompt_theme} )); then
autoload -Uz promptinit && promptinit
prompt ${zprompt_theme}
fi