mirror of
https://github.com/zsh-users/zsh-autosuggestions.git
synced 2025-04-17 11:35:31 +08:00
Checking if _zsh_highlight exists before calling it
This commit is contained in:
parent
4eeaeaeb7c
commit
95f6cbc223
@ -135,7 +135,11 @@ _zsh_autosuggest_accept() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
_zsh_autosuggest_invoke_original_widget $@
|
_zsh_autosuggest_invoke_original_widget $@
|
||||||
_zsh_highlight
|
|
||||||
|
# If zsh-syntax-highlighting is installed, we need to refresh the highlighting here
|
||||||
|
if [ `whence _zsh_highlight` ]; then
|
||||||
|
_zsh_highlight
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# Accept the entire suggestion and execute it
|
# Accept the entire suggestion and execute it
|
||||||
|
@ -411,7 +411,11 @@ _zsh_autosuggest_accept() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
_zsh_autosuggest_invoke_original_widget $@
|
_zsh_autosuggest_invoke_original_widget $@
|
||||||
_zsh_highlight
|
|
||||||
|
# If zsh-syntax-highlighting is installed, we need to refresh the highlighting here
|
||||||
|
if [ `whence _zsh_highlight` ]; then
|
||||||
|
_zsh_highlight
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# Accept the entire suggestion and execute it
|
# Accept the entire suggestion and execute it
|
||||||
|
Loading…
Reference in New Issue
Block a user