]> Sergey Matveev's repositories - vim-lsp.git/commitdiff
Always send "initializationOptions"
authorAndreas Louv <andreas@louv.dk>
Thu, 27 Apr 2023 08:12:36 +0000 (10:12 +0200)
committerAndreas Louv <andreas@louv.dk>
Thu, 27 Apr 2023 08:12:43 +0000 (10:12 +0200)
Some servers expects the object to be there. One being
https://github.com/vuejs/language-tools

autoload/lsp/lspserver.vim

index b229fdecbde41e02887b3f6954b61aaf40170d27..aedad205448a3aacc60edf23785a06aba6398819 100644 (file)
@@ -191,6 +191,8 @@ def InitServer(lspserver: dict<any>, bnr: number)
   initparams.capabilities = capabilities.GetClientCaps()
   if !lspserver.initializationOptions->empty()
     initparams.initializationOptions = lspserver.initializationOptions
+  else
+    initparams.initializationOptions = {}
   endif
 
   lspserver.rpcInitializeRequest = initparams