MCPcopy
hub / github.com/prometheus/client_js / getValueByName

Function getValueByName

test/histogramTest.js:465–475  ·  view source on GitHub ↗
(name, values)

Source from the content-addressed store, hash-verified

463 });
464 });
465 function getValueByName(name, values) {
466 return (
467 values.length > 0 &&
468 values.reduce((acc, val) => {
469 if (val.metricName === name) {
470 acc = val;
471 }
472 return acc;
473 })
474 );
475 }
476 function getValuesByName(name, values) {
477 return values.reduce((acc, val) => {
478 if (val.metricName === name) {

Callers 1

histogramTest.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected