cleanup: Leave max size config unset by default to match other options

This commit is contained in:
Eric Freese
2019-04-10 11:37:02 -06:00
parent d8ba53678e
commit db290c518b
4 changed files with 3 additions and 11 deletions

View File

@@ -122,10 +122,6 @@ typeset -g ZSH_AUTOSUGGEST_ORIGINAL_WIDGET_PREFIX=autosuggest-orig-
)
}
# Max size of buffer to trigger autosuggestion. Leave null for no upper bound.
(( ! ${+ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE} )) &&
typeset -g ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=
#--------------------------------------------------------------------#
# Utility Functions #
#--------------------------------------------------------------------#
@@ -356,7 +352,7 @@ _zsh_autosuggest_modify() {
# Get a new suggestion if the buffer is not empty after modification
if (( $#BUFFER > 0 )); then
if [[ -z "$ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE" ]] || (( $#BUFFER <= $ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE )); then
if (( ! ${+ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE} )) || (( $#BUFFER <= $ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE )); then
_zsh_autosuggest_fetch
fi
fi