Solved a bug where the options window was breaking the popup window. The issue was that some branches of the message handler in the background script weren't returning anything at all.
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
console.log('test!');
|
||||
|
||||
import Alpine from 'alpinejs';
|
||||
window.Alpine = Alpine;
|
||||
|
||||
@@ -61,11 +63,15 @@ Alpine.data('popup', () => ({
|
||||
},
|
||||
|
||||
async getNpubKey() {
|
||||
this.pubKey = await browser.runtime.sendMessage({ kind: 'getNpubKey' });
|
||||
this.pubKey = await browser.runtime.sendMessage({
|
||||
kind: 'getNpubKey',
|
||||
});
|
||||
},
|
||||
|
||||
async getHosts() {
|
||||
this.hosts = await browser.runtime.sendMessage({ kind: 'getHosts' });
|
||||
this.hosts = await browser.runtime.sendMessage({
|
||||
kind: 'getHosts',
|
||||
});
|
||||
},
|
||||
|
||||
async getProfileNames() {
|
||||
@@ -115,6 +121,11 @@ Alpine.data('popup', () => ({
|
||||
this.confirmDelete = false;
|
||||
},
|
||||
|
||||
async openOptions() {
|
||||
await browser.runtime.openOptionsPage();
|
||||
window.close();
|
||||
},
|
||||
|
||||
// Properties
|
||||
|
||||
get hasValidPubKey() {
|
||||
|
||||
Reference in New Issue
Block a user