summaryrefslogtreecommitdiff
path: root/shared/src/store.rs
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2025-01-27 15:26:00 +0100
committermetamuffin <metamuffin@disroot.org>2025-01-27 15:26:00 +0100
commitc121d94f0b27bc04ffbdca55cd0939c1401d5a2e (patch)
tree67ac9da1f994c24b9a3e8e8d2adc2e334d2e34a5 /shared/src/store.rs
parent6b5c44d58e6c6d3df360396a0897290fc603699b (diff)
downloadweareserver-c121d94f0b27bc04ffbdca55cd0939c1401d5a2e.tar
weareserver-c121d94f0b27bc04ffbdca55cd0939c1401d5a2e.tar.bz2
weareserver-c121d94f0b27bc04ffbdca55cd0939c1401d5a2e.tar.zst
clippy: fixes and ignores
Diffstat (limited to 'shared/src/store.rs')
-rw-r--r--shared/src/store.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/shared/src/store.rs b/shared/src/store.rs
index ddcee2c..b0dbe45 100644
--- a/shared/src/store.rs
+++ b/shared/src/store.rs
@@ -88,7 +88,7 @@ impl ResourceStore {
}
ResourceStore::Memory(map) => Ok(map.lock().unwrap().get(&key).map(|x| x.to_vec())),
ResourceStore::Filesystem(root) => {
- let path = fs_cache_path(&root, key);
+ let path = fs_cache_path(root, key);
if path.exists() {
let mut buf = Vec::new();
File::open(path)?.read_to_end(&mut buf)?;
@@ -113,7 +113,7 @@ impl ResourceStore {
map.lock().unwrap().insert(key, value.to_vec());
}
ResourceStore::Filesystem(root) => {
- let path = fs_cache_path(&root, key);
+ let path = fs_cache_path(root, key);
if !path.exists() {
let path_temp = path.with_extension("part");
File::create(&path_temp)?.write_all(value)?;