fix(cdk): improve error handling when adding mint to MultiMintWallet (#1099)

Add proper error handling and logging for add_mint operation instead of
propagating errors, preventing wallet operations from failing completely
when a mint cannot be added.
This commit is contained in:
thesimplekid
2025-09-22 13:53:32 +01:00
committed by GitHub
parent be7c83689d
commit 3ad860c908

View File

@@ -242,7 +242,13 @@ impl MultiMintWallet {
if mint_has_proofs_for_unit {
// Add mint to the MultiMintWallet if not already present
if !self.has_mint(&mint_url).await {
self.add_mint(mint_url, None).await?;
if let Err(err) = self.add_mint(mint_url.clone(), None).await {
tracing::error!(
"Could not add {} to wallet {}.",
mint_url,
err.to_string()
);
}
}
}
}