From adc6998617899a9b22880023d4144777c6acaafc Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Tue, 6 Jun 2023 11:09:22 +0200 Subject: [PATCH] include comment to explain key pair tenary --- dht-node/src/dht_node/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/dht-node/src/dht_node/index.ts b/dht-node/src/dht_node/index.ts index 75cecc3a7..ca00a5cee 100644 --- a/dht-node/src/dht_node/index.ts +++ b/dht-node/src/dht_node/index.ts @@ -27,6 +27,7 @@ export type CommunityApi = { export const startDHT = async (topic: string): Promise => { try { const TOPIC = DHT.hash(Buffer.from(topic)) + // uses a config defined seed or null, which will generate a random seed for the key pair const keyPair = DHT.keyPair( CONFIG.FEDERATION_DHT_SEED ? Buffer.alloc(KEY_SECRET_SEEDBYTES, CONFIG.FEDERATION_DHT_SEED)