MCPcopy Create free account
hub / github.com/cppla/ServerStatus / humanMinMBFromB

Function humanMinMBFromB

web/js/app.js:30–30  ·  view source on GitHub ↗
(bytes)

Source from the content-addressed store, hash-verified

28function humanMinMBFromKB(kb){ return humanBytes(num(kb) * 1000, 1000 * 1000); }
29function humanMinMBFromMB(mb){ return humanBytes(num(mb) * 1000 * 1000, 1000 * 1000); }
30function humanMinMBFromB(bytes){ return humanBytes(num(bytes), 1000 * 1000); }
31function humanMinKBFromB(bytes){ return humanBytes(num(bytes), 1000); }
32function humanBytes(bytes, minUnit){
33 if(!Number.isFinite(bytes)) return '-';

Callers 5

renderOverviewFunction · 0.85
trafficCapsFunction · 0.85
detailResourceHTMLFunction · 0.85
renderServersFunction · 0.85
refreshDetailFunction · 0.85

Calls 2

humanBytesFunction · 0.85
numFunction · 0.85

Tested by

no test coverage detected