MCPcopy Create free account
hub / github.com/ElementsProject/lightning / param_payment_status_nopending

Function param_payment_status_nopending

lightningd/pay.c:1636–1658  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1634AUTODATA(json_command, &listsendpays_command);
1635
1636static struct command_result *
1637param_payment_status_nopending(struct command *cmd,
1638 const char *name,
1639 const char *buffer,
1640 const jsmntok_t *tok,
1641 enum wallet_payment_status **status)
1642{
1643 struct command_result *res;
1644
1645 res = param_payment_status(cmd, name, buffer, tok, status);
1646 if (res)
1647 return res;
1648
1649 switch (**status) {
1650 case PAYMENT_COMPLETE:
1651 case PAYMENT_FAILED:
1652 break;
1653 case PAYMENT_PENDING:
1654 return command_fail_badparam(cmd, name, buffer, tok,
1655 "Cannot delete pending status");
1656 }
1657 return NULL;
1658}
1659
1660static struct command_result *json_delpay(struct command *cmd,
1661 const char *buffer,

Callers

nothing calls this directly

Calls 2

param_payment_statusFunction · 0.85
command_fail_badparamFunction · 0.85

Tested by

no test coverage detected