diff --git a/rslib/src/media/database.rs b/rslib/src/media/database.rs index 5d639f902..480bb790b 100644 --- a/rslib/src/media/database.rs +++ b/rslib/src/media/database.rs @@ -213,7 +213,9 @@ delete from media where fname=?" } pub(super) fn all_mtimes(&mut self) -> Result> { - let mut stmt = self.db.prepare("select fname, mtime from media")?; + let mut stmt = self + .db + .prepare("select fname, mtime from media where csum is not null")?; let map: std::result::Result, rusqlite::Error> = stmt .query_map(NO_PARAMS, |row| Ok((row.get(0)?, row.get(1)?)))? .collect();