.
This commit is contained in:
parent
86a8bd33a8
commit
94bd7c28a7
1 changed files with 2 additions and 2 deletions
|
@ -29,7 +29,7 @@ const PLATFORM_COLORS = {
|
|||
|
||||
const domainCache = new Map();
|
||||
async function resolvePlatform(url) {
|
||||
let urlObj = new URL(url);
|
||||
const urlObj = new URL(url);
|
||||
if (domainCache.has(urlObj.hostname)) return domainCache.get(urlObj.hostname);
|
||||
|
||||
const probe = await fetch(urlObj.origin + "/.well-known/nodeinfo", {
|
||||
|
@ -60,7 +60,7 @@ async function resolvePlatform(url) {
|
|||
}
|
||||
|
||||
async function processUrl(msg, url) {
|
||||
const urlObj = new URL(url);
|
||||
let urlObj = new URL(url);
|
||||
const platform = await resolvePlatform(url);
|
||||
const color = PLATFORM_COLORS[platform];
|
||||
const platformName = platform
|
||||
|
|
Loading…
Reference in a new issue