From 80f1cf00f2f2c4023b2066a53b51b06928d264ee Mon Sep 17 00:00:00 2001 From: kaotisk Date: Wed, 27 Dec 2023 16:54:23 +0200 Subject: Deduplication --- src/js/arching-kaos-stellar-network.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/js/arching-kaos-stellar-network.js') diff --git a/src/js/arching-kaos-stellar-network.js b/src/js/arching-kaos-stellar-network.js index 3b5ddce..ee42750 100644 --- a/src/js/arching-kaos-stellar-network.js +++ b/src/js/arching-kaos-stellar-network.js @@ -2,9 +2,13 @@ function getNumberOfTrustlinesAndRenderThem(json){ var number = json._embedded.records[0].accounts.authorized; var stats = document.querySelector('.stellar-network').querySelector('summary'); - var small = document.createElement("span"); + + if(!document.querySelector("#stellar-participants-sum")){ + var small = document.createElement("span"); + small.id = 'stellar-participants-sum'; + stats.appendChild(small); + } small.innerText = ' (' + number + ')'; - stats.appendChild(small); archingKaosLog("Loading trustlines... Found "+number+"!"); progressPlaceholder.value++; stellarParticipants=number; -- cgit v1.2.3