fix(readline): access oldComp not from readline instance

insensitive-tab
TorchedSammy 2022-04-21 12:13:08 -04:00
parent 1e868e4165
commit 1b298fd0d7
Signed by: sammyette
GPG Key ID: 904FC49417B44DCD
1 changed files with 1 additions and 1 deletions

View File

@ -21,7 +21,7 @@ func (rl *Instance) insertCandidateVirtual(candidate []rune) {
// Keep reference of previous candidate to compare its prefix
oldComp := rl.currentComp
// We place the cursor back at the beginning of the previous virtual candidate
rl.pos -= len(rl.oldComp)
rl.pos -= len(oldComp)
// We delete the previous virtual completion, just
// like we would delete a word in vim editing mode.