mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-14 20:59:25 +00:00
chore(web): Apply suggestions from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
This commit is contained in:
parent
2f9ab69b57
commit
e8d05db4d3
2 changed files with 3 additions and 4 deletions
|
|
@ -68,7 +68,7 @@ interface LanguageProcessorEventMap {
|
|||
'tryrevert': () => void,
|
||||
|
||||
/**
|
||||
* Is called synchronously as part of suggestion application when successful.
|
||||
* Is called synchronously once suggestion application is successful and the context has been updated.
|
||||
*
|
||||
* @param outputTarget The `OutputTarget` representation of the context the suggestion was applied to.
|
||||
* @returns
|
||||
|
|
|
|||
|
|
@ -77,9 +77,8 @@ export default class PredictionContext extends EventEmitter<PredictionContextEve
|
|||
this.langProcessor = langProcessor;
|
||||
this.kbdProcessor = kbdProcessor;
|
||||
|
||||
const validSuggestionState: () => boolean = () => {
|
||||
return this.currentTarget && langProcessor.state == 'configured';
|
||||
}
|
||||
const validSuggestionState: () => boolean = () =>
|
||||
this.currentTarget && langProcessor.state == 'configured';
|
||||
|
||||
this.suggestionApplier = (suggestion) => {
|
||||
if(validSuggestionState()) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue