aboutsummaryrefslogtreecommitdiff
path: root/cache/src/backends/dummy.rs
blob: 7b0efa56a7e2b5c1ba4759b2384d203293ee991c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/*
    This file is part of jellything (https://codeberg.org/metamuffin/jellything)
    which is licensed under the GNU Affero General Public License (version 3); see /COPYING.
    Copyright (C) 2026 metamuffin <metamuffin.org>
*/

use crate::backends::CacheStorage;
use anyhow::Result;

pub struct Dummy;
impl CacheStorage for Dummy {
    fn store(&self, _key: String, _value: &[u8]) -> Result<()> {
        Ok(())
    }
    fn read(&self, _key: &str) -> Result<Option<Vec<u8>>> {
        Ok(None) // sorry forgot
    }
}