Fix frontend being null if messages are received early (#575)
This commit is contained in:
parent
18f376358c
commit
1a5a37c9e4
@ -141,6 +141,7 @@ class PopupPreviewFrame {
|
|||||||
if (exampleText === null) { return; }
|
if (exampleText === null) { return; }
|
||||||
|
|
||||||
exampleText.textContent = text;
|
exampleText.textContent = text;
|
||||||
|
if (this._frontend === null) { return; }
|
||||||
this._updateSearch();
|
this._updateSearch();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -163,6 +164,7 @@ class PopupPreviewFrame {
|
|||||||
|
|
||||||
async _updateOptionsContext({optionsContext}) {
|
async _updateOptionsContext({optionsContext}) {
|
||||||
this._optionsContext = optionsContext;
|
this._optionsContext = optionsContext;
|
||||||
|
if (this._frontend === null) { return; }
|
||||||
await this._frontend.updateOptions();
|
await this._frontend.updateOptions();
|
||||||
await this._updateSearch();
|
await this._updateSearch();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user