This commit is contained in:
Simon Gardling
2022-05-17 10:15:45 -04:00
parent 149adfd614
commit 4227437475
4 changed files with 19 additions and 18 deletions

View File

@@ -146,11 +146,7 @@ impl MathApp {
fn get_storage_decompressed() -> Option<Vec<u8>> {
let data = get_localstorage().get_item(DATA_NAME).ok()??;
if crate::misc::HASH_LENGTH >= data.len() {
return None;
}
let (commit, cached_data) = crate::misc::hashed_storage_read(data)?;
let (commit, cached_data) = crate::misc::hashed_storage_read(&data)?;
debug_assert!(!commit.is_empty());
debug_assert!(!cached_data.is_empty());
@@ -188,7 +184,7 @@ impl MathApp {
return None;
}
let (commit, func_data) = crate::misc::hashed_storage_read(data)?;
let (commit, func_data) = crate::misc::hashed_storage_read(&data)?;
debug_assert!(!commit.is_empty());
debug_assert!(!func_data.is_empty());