(errorText)
| 192 | } |
| 193 | |
| 194 | function 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. |
no outgoing calls
no test coverage detected