File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -358,11 +358,11 @@ Result_InvoiceNoneZ parsed_invoice = Invoice.from_str(invoice_str);
358358
359359if (parsed_invoice instanceof Result_InvoiceNoneZ . Result_InvoiceNoneZ_OK ) {
360360 Invoice invoice = ((Result_InvoiceNoneZ . Result_InvoiceNoneZ_OK ) parsed_invoice). res;
361- long amt = 0 ;
361+ long amt_msat = 0 ;
362362 if (invoice. amount_pico_btc() instanceof Option_u64Z . Some ) {
363- amt = ((Option_u64Z . Some )invoice. amount_pico_btc()). some;
363+ amt_msat = ((Option_u64Z . Some )invoice. amount_pico_btc()). some / 10 ;
364364 }
365- if (amt == 0 ) {
365+ if (amt_msat == 0 ) {
366366 // <Handle a zero-value invoice>
367367 }
368368
@@ -372,8 +372,8 @@ if (parsed_invoice instanceof Result_InvoiceNoneZ.Result_InvoiceNoneZ_OK) {
372372 Result_RouteLightningErrorZ route_res = UtilMethods . get_route(
373373 channel_manager. get_our_node_id(),
374374 graph, invoice. recover_payee_pub_key(), invoice. features(),
375- channel_manager. list_usable_channels(), invoice. route_hints(), amt,
376- invoice. min_final_cltv_expiry(), logger);
375+ channel_manager. list_usable_channels(), invoice. route_hints(),
376+ amt_msat, invoice. min_final_cltv_expiry(), logger);
377377 assert route_res instanceof Result_RouteLightningErrorZ . Result_RouteLightningErrorZ_OK ;
378378 route = ((Result_RouteLightningErrorZ . Result_RouteLightningErrorZ_OK ) route_res). res;
379379 }
You can’t perform that action at this time.
0 commit comments