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

Function after_staticbackup

plugins/chanbackup.c:657–671  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

655}
656
657static struct command_result *after_staticbackup(struct command *cmd,
658 const char *method,
659 const char *buf,
660 const jsmntok_t *params,
661 void *cb_arg UNUSED)
662{
663 struct modern_scb_chan **scb_chan;
664 const jsmntok_t *scbs = json_get_member(buf, params, "scb");
665
666 json_to_scb_chan(buf, scbs, &scb_chan);
667 plugin_log(cmd->plugin, LOG_DBG, "Updating the SCB");
668
669 update_scb(cmd->plugin, scb_chan);
670 return send_to_peers(cmd);
671}
672
673/* Write to the datastore */
674static struct command_result *commit_peer_backup(struct command *cmd,

Callers

nothing calls this directly

Calls 5

json_get_memberFunction · 0.85
json_to_scb_chanFunction · 0.85
update_scbFunction · 0.85
send_to_peersFunction · 0.85
plugin_logFunction · 0.70

Tested by

no test coverage detected