| 69 | } |
| 70 | |
| 71 | static struct income_event *onchainfee_to_income(const tal_t *ctx, |
| 72 | struct onchain_fee *fee) |
| 73 | { |
| 74 | struct income_event *inc = tal(ctx, struct income_event); |
| 75 | |
| 76 | inc->acct_name = tal_strdup(inc, fee->acct_name); |
| 77 | inc->tag = tal_fmt(inc, "%s", ONCHAIN_FEE); |
| 78 | /* We swap these, as they're actually opposite */ |
| 79 | inc->credit = fee->debit; |
| 80 | inc->debit = fee->credit; |
| 81 | inc->fees = AMOUNT_MSAT(0); |
| 82 | inc->timestamp = fee->timestamp; |
| 83 | inc->txid = tal_dup(inc, struct bitcoin_txid, &fee->txid); |
| 84 | inc->outpoint = NULL; |
| 85 | inc->payment_id = NULL; |
| 86 | inc->desc = NULL; |
| 87 | |
| 88 | return inc; |
| 89 | } |
| 90 | |
| 91 | /* CSVs don't like ',' in the middle. We short circuit this |
| 92 | * by wrapping the desc in double-quotes ("). But what if |
no outgoing calls
no test coverage detected