mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2025-12-16 17:14:13 -05:00
feat(GUI): also poll Electrum servers for their status (#710)
This commit is contained in:
parent
cac988524f
commit
d7ca051c20
1 changed files with 15 additions and 9 deletions
|
|
@ -293,15 +293,21 @@ export async function updateAllNodeStatuses() {
|
|||
const network = getNetwork();
|
||||
const settings = store.getState().settings;
|
||||
|
||||
// Only check Monero nodes if we're using custom nodes (not RPC pool)
|
||||
// Skip Bitcoin nodes since we pass all electrum servers to the backend without checking them (ElectrumBalancer handles failover)
|
||||
if (!settings.useMoneroRpcPool) {
|
||||
await Promise.all(
|
||||
settings.nodes[network][Blockchain.Monero].map((node) =>
|
||||
updateNodeStatus(node, Blockchain.Monero, network),
|
||||
),
|
||||
);
|
||||
}
|
||||
// We pass all electrum servers to the backend without checking them (ElectrumBalancer handles failover),
|
||||
// but check these anyway since the status appears in the GUI.
|
||||
// Only check Monero nodes if we're using custom nodes (not RPC pool).
|
||||
await Promise.all(
|
||||
(settings.useMoneroRpcPool
|
||||
? [Blockchain.Bitcoin]
|
||||
: [Blockchain.Bitcoin, Blockchain.Monero]
|
||||
)
|
||||
.map((blockchain) =>
|
||||
settings.nodes[network][blockchain].map((node) =>
|
||||
updateNodeStatus(node, blockchain, network),
|
||||
),
|
||||
)
|
||||
.flat(),
|
||||
);
|
||||
}
|
||||
|
||||
export async function cheapCheckBitcoinBalance() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue