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

Function recurrence_time_unit_name

plugins/offers.c:284–300  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

282}
283
284static const char *recurrence_time_unit_name(u8 time_unit)
285{
286 /* BOLT-offers-recurrence #12:
287 * `time_unit` defining 0 (seconds), 1 (days), 2 (months), 3 (years).
288 */
289 switch (time_unit) {
290 case 0:
291 return "seconds";
292 case 1:
293 return "days";
294 case 2:
295 return "months";
296 case 3:
297 return "years";
298 }
299 return NULL;
300}
301
302static void json_add_offer(struct json_stream *js, const struct tlv_offer *offer)
303{

Callers 1

json_add_offerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected