aboutsummaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2019-12-23 16:52:05 -0500
committertoasted-nutbread <toasted-nutbread@users.noreply.github.com>2020-01-22 20:38:21 -0500
commit22afab2f47bcc1e5e9ac0db35d2f1b168becf76e (patch)
treef9b44122a32e2dbd77054985dcbf015d304e71b3 /ext
parente51fd8ea71b361ef439728ba6985cbc30c057cd0 (diff)
Remove _isInitialized
Diffstat (limited to 'ext')
-rw-r--r--ext/fg/js/popup.js6
1 files changed, 1 insertions, 5 deletions
diff --git a/ext/fg/js/popup.js b/ext/fg/js/popup.js
index 9b3e3944..12a5c1c2 100644
--- a/ext/fg/js/popup.js
+++ b/ext/fg/js/popup.js
@@ -104,7 +104,7 @@ class Popup {
}
async showContent(elementRect, writingMode, type=null, details=null) {
- if (!this._isInitialized()) { return; }
+ if (this._options === null) { throw new Error('Options not assigned'); }
await this._show(elementRect, writingMode);
if (type === null) { return; }
this._invokeApi('setContent', {type, details});
@@ -236,10 +236,6 @@ class Popup {
});
}
- _isInitialized() {
- return this._options !== null;
- }
-
async _show(elementRect, writingMode) {
await this._inject();