| 158 | } |
| 159 | |
| 160 | static void onionmessage_forward_fail_serialize(struct json_stream *stream, |
| 161 | const struct node_id *source, |
| 162 | const u8 *incoming, |
| 163 | const struct pubkey *path_key, |
| 164 | const u8 *outgoing, |
| 165 | const struct sciddir_or_pubkey *next_node) |
| 166 | { |
| 167 | json_add_node_id(stream, "source", source); |
| 168 | json_add_hex_talarr(stream, "incoming", incoming); |
| 169 | json_add_pubkey(stream, "path_key", path_key); |
| 170 | if (tal_count(outgoing) != 0) { |
| 171 | json_add_hex_talarr(stream, "outgoing", outgoing); |
| 172 | if (next_node->is_pubkey) |
| 173 | json_add_pubkey(stream, "next_node_id", &next_node->pubkey); |
| 174 | else |
| 175 | json_add_short_channel_id_dir(stream, "next_short_channel_id_dir", |
| 176 | next_node->scidd); |
| 177 | } |
| 178 | } |
| 179 | |
| 180 | REGISTER_NOTIFICATION(onionmessage_forward_fail); |
| 181 |
no test coverage detected