From da2200ffd1bf1f812c477b8387654842d2b80095 Mon Sep 17 00:00:00 2001 From: Brian Botha Date: Mon, 20 Mar 2023 10:41:58 +1100 Subject: [PATCH] fix: changing order of discovery message spam fix * Related #514 [ci skip] --- src/nodes/NodeManager.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/nodes/NodeManager.ts b/src/nodes/NodeManager.ts index 21d1b00ab7..9b5ff8abbc 100644 --- a/src/nodes/NodeManager.ts +++ b/src/nodes/NodeManager.ts @@ -1167,6 +1167,10 @@ class NodeManager { logger.info('Syncing nodeGraph'); // Getting the seed node connection information const seedNodes = this.nodeConnectionManager.getSeedNodes(); + if (seedNodes.length === 0) { + logger.debug(`No seed nodes provided, skipping discovery`); + return; + } const addresses = await Promise.all( await this.db.withTransactionF(async (tran) => seedNodes.map( @@ -1190,10 +1194,6 @@ class NodeManager { (address) => `${address.host}:${address.port}`, )}`, ); - if (seedNodes.length === 0) { - logger.debug(`No seed nodes provided, skipping discovery`); - return; - } // Establishing connections to the seed nodes const connections = await this.nodeConnectionManager.establishMultiConnection(