diff --git a/src/highlight.zsh b/src/highlight.zsh index 273c03d..bae52e5 100644 --- a/src/highlight.zsh +++ b/src/highlight.zsh @@ -8,7 +8,7 @@ _zsh_autosuggest_highlight_reset() { typeset -g _ZSH_AUTOSUGGEST_LAST_HIGHLIGHT if [[ -n "$_ZSH_AUTOSUGGEST_LAST_HIGHLIGHT" ]]; then - region_highlight=("${(@)region_highlight:#$_ZSH_AUTOSUGGEST_LAST_HIGHLIGHT}") + shift -p region_highlight unset _ZSH_AUTOSUGGEST_LAST_HIGHLIGHT fi } diff --git a/zsh-autosuggestions.zsh b/zsh-autosuggestions.zsh index b19cac7..e281b84 100644 --- a/zsh-autosuggestions.zsh +++ b/zsh-autosuggestions.zsh @@ -244,7 +244,7 @@ _zsh_autosuggest_highlight_reset() { typeset -g _ZSH_AUTOSUGGEST_LAST_HIGHLIGHT if [[ -n "$_ZSH_AUTOSUGGEST_LAST_HIGHLIGHT" ]]; then - region_highlight=("${(@)region_highlight:#$_ZSH_AUTOSUGGEST_LAST_HIGHLIGHT}") + shift -p region_highlight unset _ZSH_AUTOSUGGEST_LAST_HIGHLIGHT fi }