global: snapshot

This commit is contained in:
k
2024-10-04 19:09:09 +02:00
parent 1c9d118ba2
commit 068bb07d6e
57 changed files with 1799 additions and 295 deletions

View File

@@ -2,8 +2,6 @@ use std::time::Instant;
use crate::utils::log;
use super::ONE_DAY_IN_S;
pub fn time<F, T>(name: &str, function: F) -> T
where
F: FnOnce() -> T,
@@ -16,11 +14,3 @@ where
returned
}
pub fn difference_in_days_between_timestamps(older: u32, younger: u32) -> u32 {
if younger <= older {
0
} else {
(younger - older) / ONE_DAY_IN_S as u32
}
}