Skip to content

Commit

Permalink
fixup! Add wasm support
Browse files Browse the repository at this point in the history
  • Loading branch information
danielabrozzoni committed Sep 20, 2022
1 parent 9974255 commit 44a04ec
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/wasm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ impl WasmWallet {
#[wasm_bindgen(constructor)]
pub fn new(network: JsValue, wallet_opts: Vec<JsValue>) -> Result<WasmWallet, String> {
fn new_inner(
network: JsValue,
network: String,
wallet_opts: Vec<JsValue>,
) -> Result<WasmWallet, Box<dyn Error>> {
// Both open_database and new_blockchain need a home path to be passed
Expand Down Expand Up @@ -157,7 +157,7 @@ pub fn compile(policy: String, aliases: String, script_type: String) -> Result<J
);
let descriptor = descriptor?;

Ok(format!("{}", descriptor).into())
Ok(descriptor.to_string().into())
}

compile_inner(policy, aliases, script_type)
Expand Down

0 comments on commit 44a04ec

Please sign in to comment.