MCPcopy Create free account
hub / github.com/TeleBoxOrg/TeleBox_Plugins / htmlEscape

Function htmlEscape

speedlink/speedlink.ts:340–346  ·  view source on GitHub ↗
(text: any)

Source from the content-addressed store, hash-verified

338 }
339}
340
341// Fixed htmlEscape function
342async function unitConvert(bytes: number, isBytes: boolean = false): Promise<string> {
343 const power = 1000;
344 let value = bytes;
345 let unitIndex = 0;
346 const units = isBytes
347 ? ["B", "KB", "MB", "GB", "TB"]
348 : ["bps", "Kbps", "Mbps", "Gbps", "Tbps"];
349 if (!isBytes) value *= 8;

Callers 1

speedtestFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected