refactor(bindings): remove payment method enum

This commit is contained in:
thesimplekid
2024-05-10 10:41:33 +01:00
parent 81fd6b7756
commit 4a3e74e129
2 changed files with 0 additions and 26 deletions

View File

@@ -2,7 +2,6 @@ pub mod blind_signature;
pub mod blinded_message;
pub mod currency_unit;
pub mod mint_proofs;
pub mod payment_method;
pub mod premint;
pub mod proof;
pub mod token;
@@ -10,7 +9,6 @@ pub mod witness;
pub use blinded_message::JsBlindedMessage;
pub use currency_unit::JsCurrencyUnit;
pub use payment_method::JsPaymentMethod;
pub use premint::{JsPreMint, JsPreMintSecrets};
pub use proof::JsProof;
pub use token::JsToken;

View File

@@ -1,24 +0,0 @@
use cdk::nuts::PaymentMethod;
use wasm_bindgen::prelude::*;
#[wasm_bindgen(js_name = PaymentMethod)]
pub enum JsPaymentMethod {
Bolt11,
}
impl From<PaymentMethod> for JsPaymentMethod {
fn from(inner: PaymentMethod) -> JsPaymentMethod {
match inner {
PaymentMethod::Bolt11 => JsPaymentMethod::Bolt11,
PaymentMethod::Custom(_) => todo!(),
}
}
}
impl From<JsPaymentMethod> for PaymentMethod {
fn from(inner: JsPaymentMethod) -> PaymentMethod {
match inner {
JsPaymentMethod::Bolt11 => PaymentMethod::Bolt11,
}
}
}