MCPcopy Create free account
hub / github.com/EvoMap/evolver / parseShortfall

Function parseShortfall

src/gep/validator/stakeBootstrap.js:194–198  ·  view source on GitHub ↗
(errorText)

Source from the content-addressed store, hash-verified

192}
193
194function parseShortfall(errorText) {
195 const match = String(errorText || '').match(/need\s+(\d+(?:\.\d+)?),\s*have\s+(\d+(?:\.\d+)?)/i);
196 if (!match) return null;
197 return { need: Number(match[1]), have: Number(match[2]) };
198}
199
200/**
201 * Attempt to stake credits so this node becomes eligible for validation tasks.

Callers 1

ensureValidatorStakeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected