Skip to content

Commit

Permalink
Update README example to use Bolt11Invoice
Browse files Browse the repository at this point in the history
  • Loading branch information
tnull committed Dec 20, 2023
1 parent 2878217 commit 83b5897
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The primary abstraction of the library is the [`Node`][api_docs_node], which can

```rust
use ldk_node::{Builder, Network};
use ldk_node::lightning_invoice::Invoice;
use ldk_node::lightning_invoice::Bolt11Invoice;
use ldk_node::lightning::ln::msgs::SocketAddress;
use ldk_node::bitcoin::secp256k1::PublicKey;
use std::str::FromStr;
Expand All @@ -39,7 +39,7 @@ fn main() {
println!("EVENT: {:?}", event);
node.event_handled();

let invoice = Invoice::from_str("INVOICE_STR").unwrap();
let invoice = Bolt11Invoice::from_str("INVOICE_STR").unwrap();
node.send_payment(&invoice).unwrap();

node.stop().unwrap();
Expand Down

0 comments on commit 83b5897

Please sign in to comment.