fix +format/region when formatting with LSP

This commit is contained in:
Tudor Roman 2020-05-26 18:16:23 +03:00
parent ca0dbc798d
commit 649052337b
No known key found for this signature in database
GPG key ID: 5AFEDD03CA5A1EA4

View file

@ -223,7 +223,7 @@ snippets or single lines."
(if (and +format-with-lsp
(bound-and-true-p lsp-mode)
(lsp-feature? "textDocument/rangeFormatting"))
#'lsp-format-region
(call-interactively #'lsp-format-region)
(save-restriction
(narrow-to-region beg end)
(let ((+format-region-p t))