Pārlūkot izejas kodu

add pubkey to mint info if not set

Darrell 2 mēneši atpakaļ
vecāks
revīzija
a62decfc24
1 mainītis faili ar 8 papildinājumiem un 0 dzēšanām
  1. 8 0
      crates/cdk/src/mint/mod.rs

+ 8 - 0
crates/cdk/src/mint/mod.rs

@@ -161,6 +161,14 @@ impl Mint {
                 .count()
         );
 
+        let mint_info = if mint_info.pubkey.is_none() {
+            let mut info = mint_info;
+            info.pubkey = Some(keysets.pubkey);
+            info
+        } else {
+            mint_info
+        };
+
         let mint_store = localstore.clone();
         let mut tx = mint_store.begin_transaction().await?;
         tx.set_mint_info(mint_info.clone()).await?;