Skip to content

Commit 5256c79

Browse files
[NCM] Fix incorrect keyword used for completion
My previous calculation was incorrect for lines with multiple keywords. NCM has already performed the regex calculation & saved me time, so there is no need for me to repeat it. This is both a performance boost & bug fix
1 parent aeefb6a commit 5256c79

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pythonx/cm_sources/fireplace.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@ def __init__(self,nvim):
2222

2323
def cm_refresh(self,info,ctx):
2424
getLogger(__name__).debug('Running a refresh…')
25-
matches = self._cider_completion_manager.gather_candidates(re.search(info['word_pattern'], ctx['typed']).group(0))
25+
matches = self._cider_completion_manager.gather_candidates(ctx['base'])
2626
self._nvim.call('cm#complete', info['name'], ctx, ctx['startcol'], matches, 1, async=True)

0 commit comments

Comments
 (0)