bunker improvements.

This commit is contained in:
fiatjaf
2024-03-02 08:18:40 -03:00
parent ffe2db7f96
commit 34c189af28
4 changed files with 30 additions and 22 deletions

View File

@@ -142,7 +142,9 @@ func gatherSecretKeyOrBunkerFromArguments(c *cli.Context) (string, *nip46.Bunker
} else {
clientKey = nostr.GeneratePrivateKey()
}
bunker, err := nip46.ConnectBunker(c.Context, clientKey, bunkerURL, nil)
bunker, err := nip46.ConnectBunker(c.Context, clientKey, bunkerURL, nil, func(s string) {
fmt.Fprintf(os.Stderr, color.CyanString("[nip46]: open the following URL: %s"), s)
})
return "", bunker, err
}
sec := c.String("sec")