Skip to content

Commit

Permalink
fix(source-language): fix range of textEdit
Browse files Browse the repository at this point in the history
Closes #3374
  • Loading branch information
chemzqm committed Dec 21, 2021
1 parent b532597 commit f59f77c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sources/source-language.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ export default class LanguageSource implements ISource {
let line = opt.linenr - 1
if (item.insertText != null && !item.textEdit) {
item.textEdit = {
range: Range.create(line, opt.col, line, opt.colnr - 1),
range: Range.create(line, characterIndex(opt.line, opt.col), line, characterIndex(opt.line, opt.colnr - 1)),
newText: item.insertText
}
}
Expand Down

0 comments on commit f59f77c

Please sign in to comment.