From ae3a20cfd5ea89919326a6499c5a3c93fdfe2120 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Wed, 8 Jul 2020 19:51:10 +0800 Subject: fix #187 --- script/method/textDocument/didChange.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'script/method/textDocument/didChange.lua') diff --git a/script/method/textDocument/didChange.lua b/script/method/textDocument/didChange.lua index 83701662..fd8af6ba 100644 --- a/script/method/textDocument/didChange.lua +++ b/script/method/textDocument/didChange.lua @@ -1,3 +1,5 @@ +local fn = require 'filename' + --- @param lsp LSP --- @param params table --- @return boolean @@ -7,7 +9,7 @@ return function (lsp, params) local ws = lsp:findWorkspaceFor(doc.uri) if ws then local path = ws:relativePathByUri(doc.uri) - if not path or not ws:isLuaFile(path) then + if not path or not fn.isLuaFile(path) then return end if not lsp:isOpen(doc.uri) and ws.gitignore(path:string()) then -- cgit v1.2.3