fix build

This commit is contained in:
hzrd149
2024-04-18 09:00:44 -05:00
parent 24c664eb08
commit e09a9a4dbe
3 changed files with 3 additions and 2 deletions

View File

@@ -104,6 +104,7 @@ class AccountService {
db.put("accounts", account);
}
addFromNostrConnect(client: NostrConnectClient) {
if (!client.pubkey) throw new Error("Cant add client without pubkey");
this.addAccount({
type: "nostr-connect",
signerRelays: client.relays,

View File

@@ -103,7 +103,7 @@ export default function LoginNostrAddressCreate() {
nostrConnectService.saveClient(client);
accountService.addFromNostrConnect(client);
accountService.switchAccount(client.pubkey);
accountService.switchAccount(client.pubkey!);
} catch (e) {
if (e instanceof Error) toast({ description: e.message, status: "error" });
}

View File

@@ -47,7 +47,7 @@ export default function LoginNostrAddressView() {
nostrConnectService.saveClient(client);
accountService.addFromNostrConnect(client);
accountService.switchAccount(client.pubkey);
accountService.switchAccount(client.pubkey!);
} else {
accountService.addAccount({
type: "pubkey",