MCPcopy Create free account
hub / github.com/Openpanel-dev/openpanel / resolveHostname

Function resolveHostname

apps/api/src/controllers/tools.controller.ts:238–245  ·  view source on GitHub ↗
(hostname: string)

Source from the content-addressed store, hash-verified

236}
237
238async function resolveHostname(hostname: string): Promise<string> {
239 try {
240 const addresses = await dns.resolve4(hostname);
241 return addresses[0] || '';
242 } catch {
243 return '';
244 }
245}
246
247interface IPInfo {
248 isp: string | null;

Callers 1

siteCheckerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected