Should we finish command now? */
| 443 | |
| 444 | /* Should we finish command now? */ |
| 445 | static bool should_finish_command(const struct payment *payment) |
| 446 | { |
| 447 | const struct xpay *xpay = xpay_of(payment->plugin); |
| 448 | |
| 449 | if (!xpay->slow_mode) |
| 450 | return true; |
| 451 | |
| 452 | /* In slow mode, only finish when no remaining attempts |
| 453 | * (caller has already moved it to past_attempts). */ |
| 454 | return list_empty(&payment->current_attempts); |
| 455 | } |
| 456 | |
| 457 | static void payment_succeeded(struct payment *payment, |
| 458 | const struct preimage *preimage) |
no test coverage detected