Skip to content

Commit

Permalink
Merge pull request #3 from 0xsommerfeld/route-hints
Browse files Browse the repository at this point in the history
  • Loading branch information
benthecarman authored Mar 27, 2024
2 parents 6452894 + 2ef8221 commit 7384ee4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ pub struct Config {
#[clap(long)]
/// Path to admin.macaroon file for lnd
macaroon_file: Option<String>,
#[clap(long)]
/// Include route hints in invoices
pub route_hints: bool,
}

impl Config {
Expand Down
1 change: 1 addition & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -428,6 +428,7 @@ async fn handle_nwc_params(
description_hash,
value_msat: params.amount as i64,
expiry: params.expiry.unwrap_or(86_400) as i64,
private: config.route_hints,
..Default::default()
};
let res = lnd.add_invoice(inv).await?.into_inner();
Expand Down

0 comments on commit 7384ee4

Please sign in to comment.