Browse Source

feat(mint): update mint url

thesimplekid 8 months ago
parent
commit
e358401ec8
1 changed files with 20 additions and 10 deletions
  1. 20 10
      crates/cdk/src/mint/mod.rs

+ 20 - 10
crates/cdk/src/mint/mod.rs

@@ -86,6 +86,26 @@ impl Mint {
         })
     }
 
+    /// Set Mint Url
+    pub fn set_mint_url(&mut self, mint_url: UncheckedUrl) {
+        self.mint_url = mint_url;
+    }
+
+    /// Get Mint Url
+    pub fn get_mint_url(&self) -> &UncheckedUrl {
+        &self.mint_url
+    }
+
+    /// Set Mint Info
+    pub fn set_mint_info(&mut self, mint_info: MintInfo) {
+        self.mint_info = mint_info;
+    }
+
+    /// Get Mint Info
+    pub fn mint_info(&self) -> &MintInfo {
+        &self.mint_info
+    }
+
     /// New mint quote
     pub async fn new_mint_quote(
         &self,
@@ -721,16 +741,6 @@ impl Mint {
         })
     }
 
-    /// Set Mint Info
-    pub fn set_mint_info(&mut self, mint_info: MintInfo) {
-        self.mint_info = mint_info;
-    }
-
-    /// Get Mint Info
-    pub fn mint_info(&self) -> Result<MintInfo, Error> {
-        Ok(self.mint_info.clone())
-    }
-
     /// Restore
     pub async fn restore(&self, request: RestoreRequest) -> Result<RestoreResponse, Error> {
         let output_len = request.outputs.len();