diff --git a/Cargo.toml b/Cargo.toml index 37eb9dd..d41414d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -15,7 +15,7 @@ async-std = { version = "1.10.0", features = ["unstable"], optional = true } digest = "0.10.6" either = "1.6.1" futures = { version = "0.3.17", optional = true } -hex = "0.4.3" +const-hex = "1.0.0" memmap2 = { version = "0.5.8", optional = true } miette = "5.7.0" reflink-copy = "0.1.9" diff --git a/src/index.rs b/src/index.rs index b9f5257..8fc21c2 100644 --- a/src/index.rs +++ b/src/index.rs @@ -309,13 +309,13 @@ fn bucket_path(cache: &Path, key: &str) -> PathBuf { fn hash_key(key: &str) -> String { let mut hasher = Sha1::new(); hasher.update(key); - hex::encode(hasher.finalize()) + const_hex::encode(hasher.finalize()) } fn hash_entry(key: &str) -> String { let mut hasher = Sha256::new(); hasher.update(key); - hex::encode(hasher.finalize()) + const_hex::encode(hasher.finalize()) } fn now() -> u128 {