Merge pull request #2335 from mempool/nymkappa/bugfix/most-connected-node-undefined

Fix undefined public_key
This commit is contained in:
wiz authored and GitHub committed 2022-08-20 20:18:30 +09:00
commit 406a65cfb6
1 file changed
+1 -1
+1 -1
View File
@@ -169,7 +169,7 @@ class NodesApi {
let query: string;
if (full === false) {
query = `
SELECT nodes.public_key, IF(nodes.alias = '', SUBSTRING(nodes.public_key, 1, 20), alias) as alias,
SELECT nodes.public_key as publicKey, IF(nodes.alias = '', SUBSTRING(nodes.public_key, 1, 20), alias) as alias,
node_stats.channels
FROM node_stats
JOIN nodes ON nodes.public_key = node_stats.public_key