aboutsummaryrefslogtreecommitdiff
path: root/src/console
diff options
context:
space:
mode:
Diffstat (limited to 'src/console')
-rw-r--r--src/console/components/console.js10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/console/components/console.js b/src/console/components/console.js
index 4a4b66a..8b69df9 100644
--- a/src/console/components/console.js
+++ b/src/console/components/console.js
@@ -4,7 +4,6 @@ import * as consoleActions from 'console/actions/console';
export default class ConsoleComponent {
constructor(wrapper, store) {
this.wrapper = wrapper;
- this.prevValue = '';
this.prevState = {};
this.completionOrigin = '';
this.store = store;
@@ -50,19 +49,13 @@ export default class ConsoleComponent {
}
onInput(e) {
- let targetValue = e.target.value;
- if (targetValue === this.prevValue) {
- return;
- }
-
let doc = this.wrapper.ownerDocument;
let input = doc.querySelector('#vimvixen-console-command-input');
this.completionOrigin = input.value;
- this.prevValue = targetValue;
return browser.runtime.sendMessage({
type: messages.CONSOLE_QUERY_COMPLETIONS,
- text: targetValue
+ text: e.target.value,
}).then((completions) => {
this.store.dispatch(consoleActions.setCompletions(completions));
});
@@ -107,7 +100,6 @@ export default class ConsoleComponent {
input.focus();
window.focus();
- this.prevValue = '';
this.onInput({ target: input });
}