[M] Move ReturnPath to Generator
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
use std::os::unix::fs::MetadataExt;
|
||||
use pathdiff::diff_paths;
|
||||
use std::path::{PathBuf};
|
||||
use serde::{de, Deserialize, ser, Serialize};
|
||||
|
||||
const DOT_PATH: &str = ".meow_index";
|
||||
|
||||
@@ -16,6 +17,12 @@ pub fn generate_thumb(base: PathBuf, file: PathBuf) -> Result<(), String>
|
||||
// Thumbnail already up to date
|
||||
(Ok(tm), Ok(fm)) => if tm.mtime() >= fm.mtime() { return Ok(()) },
|
||||
_ => {}
|
||||
#[derive(Serialize, Deserialize)]
|
||||
pub struct ReturnPath {
|
||||
pub(crate) name: String,
|
||||
pub(crate) file_type: String,
|
||||
pub(crate) mtime: i64
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user