fix: ternserver code (#16179)

## Description

Hotfix to resolve `focusedValue` undefined error 
## Type of change

- Bug fix (non-breaking change which fixes an issue)

## How Has This Been Tested?



## Checklist:

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my feature works
- [ ] New and existing unit tests pass locally with my changes
This commit is contained in:
Rishabh Rathod 2022-08-22 13:37:03 +05:30 committed by Rishabh-Rathod
parent 2ec11a4dee
commit 1660092c79

View File

@ -207,7 +207,9 @@ class TernServer {
}
const doc = this.findDoc(cm.getDoc());
const cursor = cm.getCursor();
const { extraChars } = this.getFocusedDocValueAndPos(doc);
const { extraChars, value: focusedValue } = this.getFocusedDocValueAndPos(
doc,
);
let completions: Completion[] = [];
let after = "";