This commit is contained in:
hrsh7th
2021-10-11 16:29:42 +09:00
parent 071c08fcc9
commit 2f2794decd
8 changed files with 23 additions and 18 deletions

View File

@@ -346,9 +346,9 @@ end
entry.match = function(self, input)
return self.match_cache:ensure(input, function()
local score, matches, _
score, matches = matcher.match(input, self:get_filter_text(), { self:get_word() })
score, matches = matcher.match(input, self:get_filter_text(), { self:get_word(), self:get_completion_item().label })
if self:get_filter_text() ~= self:get_completion_item().label then
_, matches = matcher.match(input, self:get_completion_item().label)
_, matches = matcher.match(input, self:get_completion_item().label, { self:get_word() })
end
return { score = score, matches = matches }
end)