diff --git a/lua/lspconfig/server_configurations/pyright.lua b/lua/lspconfig/server_configurations/pyright.lua index 2ae18dca50..2f727418a2 100644 --- a/lua/lspconfig/server_configurations/pyright.lua +++ b/lua/lspconfig/server_configurations/pyright.lua @@ -34,7 +34,7 @@ return { cmd = { 'pyright-langserver', '--stdio' }, filetypes = { 'python' }, root_dir = function(fname) - return util.root_pattern(unpack(root_files))(fname) or vim.loop.cwd() + return util.root_pattern(unpack(root_files))(fname) end, single_file_support = true, settings = {