diff --git a/core/src/utils.rs b/core/src/utils.rs index 04446cf..22ab901 100644 --- a/core/src/utils.rs +++ b/core/src/utils.rs @@ -89,6 +89,10 @@ pub async fn get_seed_from_locked_device_bundle( /// unlock seed_bundles to access the pub-key and seed pub async fn unlock(device_bundle: &str, passphrase: &str) -> SeedExplorerResult { + if device_bundle.is_empty() { + bail!("called with device_bundle"); + } + let cipher = base64::decode_config(device_bundle, base64::URL_SAFE_NO_PAD)?; match UnlockedSeedBundle::from_locked(&cipher).await?.remove(0) { LockedSeedCipher::PwHash(cipher) => {