mirror of
https://github.com/hzrd149/nostrudel.git
synced 2025-04-13 22:29:18 +02:00
add bootstrap relays if ext dose not provide any
This commit is contained in:
parent
8e88656f7e
commit
dbfcf14cbd
@ -10,7 +10,7 @@ export default function LoginNpubView() {
|
||||
const navigate = useNavigate();
|
||||
const toast = useToast();
|
||||
const [npub, setNpub] = useState("");
|
||||
const [relayUrl, setRelayUrl] = useState("");
|
||||
const [relayUrl, setRelayUrl] = useState("wss://relay.damus.io");
|
||||
|
||||
const handleSubmit: React.FormEventHandler<HTMLDivElement> = (e) => {
|
||||
e.preventDefault();
|
||||
|
@ -26,6 +26,10 @@ export default function LoginStartView() {
|
||||
relays = Object.keys(extRelays).filter((url) => extRelays[url].read);
|
||||
}
|
||||
|
||||
if (relays.length === 0) {
|
||||
relays = ["wss://relay.damus.io", "wss://relay.snort.social", "wss://nostr.wine"];
|
||||
}
|
||||
|
||||
accountService.addAccount({ pubkey, relays, useExtension: true });
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user