1
0
Files
AstralRinth/apps/labrinth/src/util/date.rs
2024-10-16 14:11:42 -07:00

10 lines
294 B
Rust

use chrono::Utc;
// this converts timestamps to the timestamp format clickhouse requires/uses
pub fn get_current_tenths_of_ms() -> i64 {
Utc::now()
.timestamp_nanos_opt()
.expect("value can not be represented in a timestamp with nanosecond precision.")
/ 100_000
}