nip46: fix pubkey passed to "connect".

This commit is contained in:
fiatjaf 2024-03-04 09:30:45 -03:00
parent d690fd7f07
commit aea2895441
No known key found for this signature in database
GPG Key ID: BAD43C4BE5C1A3A1
2 changed files with 2 additions and 4 deletions

View File

@ -77,8 +77,7 @@ func ConnectBunker(
onAuth,
)
clientPubKey, _ := nostr.GetPublicKey(clientSecretKey)
_, err = bunker.RPC(ctx, "connect", []string{clientPubKey, secret})
_, err = bunker.RPC(ctx, "connect", []string{targetPublicKey, secret})
return bunker, err
}

View File

@ -50,8 +50,7 @@ func CreateAccount(
onAuth,
)
clientPubKey, _ := nostr.GetPublicKey(clientSecretKey)
_, err = bunker.RPC(ctx, "connect", []string{clientPubKey, ""})
_, err = bunker.RPC(ctx, "connect", []string{providerPubkey, ""})
if err != nil {
return nil, fmt.Errorf("initial connect error: %w", err)
}