Skip to content

Commit

Permalink
bindings: export Display for Amp2Descriptor
Browse files Browse the repository at this point in the history
  • Loading branch information
RCasatta committed Jan 8, 2025
1 parent 7716fe2 commit 7f18378
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lwk_bindings/src/amp2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,17 @@ pub struct Amp2 {

/// Wrapper over [`lwk_wollet::amp2::Amp2Descriptor`]
#[derive(uniffi::Object)]
#[uniffi::export(Display)]
pub struct Amp2Descriptor {
inner: lwk_wollet::amp2::Amp2Descriptor,
}

impl std::fmt::Display for Amp2Descriptor {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{:?}", self.inner)
}
}

#[uniffi::export]
impl Amp2Descriptor {
pub fn descriptor(&self) -> WolletDescriptor {
Expand Down

0 comments on commit 7f18378

Please sign in to comment.