Skip to content

Commit c7483f8

Browse files
committed
f Account for CurrencyCode changes
1 parent 8568e8e commit c7483f8

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/ffi/types.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -126,9 +126,8 @@ impl From<LdkAmount> for OfferAmount {
126126
fn from(ldk_amount: LdkAmount) -> Self {
127127
match ldk_amount {
128128
LdkAmount::Bitcoin { amount_msats } => OfferAmount::Bitcoin { amount_msats },
129-
LdkAmount::Currency { iso4217_code, amount } => OfferAmount::Currency {
130-
iso4217_code: iso4217_code.iter().map(|&b| b as char).collect(),
131-
amount,
129+
LdkAmount::Currency { iso4217_code, amount } => {
130+
OfferAmount::Currency { iso4217_code: iso4217_code.as_str().to_owned(), amount }
132131
},
133132
}
134133
}

0 commit comments

Comments
 (0)