aboutsummaryrefslogtreecommitdiff
path: root/ext/fg/js/popup.js
diff options
context:
space:
mode:
authorAlex Yatskov <alex@foosoft.net>2016-07-23 19:06:33 -0700
committerAlex Yatskov <alex@foosoft.net>2016-07-23 19:06:33 -0700
commite062ae2063b4a4aa3b284816adee3350e5670a20 (patch)
tree4d24bb9caa32bdd4a700bee850699a388e9d064a /ext/fg/js/popup.js
parentb2c19ab9c9ec6034f19d23a3912080bc6e638a2b (diff)
Support looking up definitions for buttons and inputs.
Diffstat (limited to 'ext/fg/js/popup.js')
-rw-r--r--ext/fg/js/popup.js12
1 files changed, 7 insertions, 5 deletions
diff --git a/ext/fg/js/popup.js b/ext/fg/js/popup.js
index 11b25d8f..78106319 100644
--- a/ext/fg/js/popup.js
+++ b/ext/fg/js/popup.js
@@ -58,12 +58,14 @@ class Popup {
}
setContent(content) {
- if (this.popup !== null) {
- const doc = this.popup.contentDocument;
- doc.open();
- doc.write(content);
- doc.close();
+ if (this.popup === null) {
+ return;
}
+
+ const doc = this.popup.contentDocument;
+ doc.open();
+ doc.write(content);
+ doc.close();
}
sendMessage(action, params, callback) {