mirror of https://github.com/zkat/cacache-rs.git
fix(content): make rm use our own Error
This commit is contained in:
parent
815d7a3c9e
commit
f3b6abf45c
|
|
@ -1,9 +1,12 @@
|
|||
use crate::content::path;
|
||||
use ssri::Integrity;
|
||||
use std::io;
|
||||
use std::fs;
|
||||
use std::path::Path;
|
||||
|
||||
pub fn rm(cache: &Path, sri: &Integrity) -> io::Result<()> {
|
||||
fs::remove_file(path::content_path(&cache, &sri))
|
||||
use ssri::Integrity;
|
||||
|
||||
use crate::content::path;
|
||||
use crate::errors::Error;
|
||||
|
||||
pub fn rm(cache: &Path, sri: &Integrity) -> Result<(), Error> {
|
||||
fs::remove_file(path::content_path(&cache, &sri))?;
|
||||
Ok(())
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue