tools/lsp: fix lsp-workspace-restart

This commit is contained in:
Henrik Lissner 2019-11-02 15:50:02 -04:00
parent 9fbfc44f73
commit f6d3ee5889
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -38,7 +38,9 @@ This can be a single company backend or a list thereof. It can be anything
This gives the user a chance to open other project files before the server is This gives the user a chance to open other project files before the server is
auto-killed (which is usually an expensive process)." auto-killed (which is usually an expensive process)."
:around #'lsp--shutdown-workspace :around #'lsp--shutdown-workspace
(if lsp-keep-workspace-alive (if (or lsp-keep-workspace-alive
(eq (lsp--workspace-shutdown-action lsp--cur-workspace)
'restart))
(funcall orig-fn) (funcall orig-fn)
(when (timerp +lsp--deferred-shutdown-timer) (when (timerp +lsp--deferred-shutdown-timer)
(cancel-timer +lsp--deferred-shutdown-timer)) (cancel-timer +lsp--deferred-shutdown-timer))