mirror of
https://github.com/pezkuwichain/pezkuwi-telemetry.git
synced 2026-07-10 16:57:22 +00:00
Move a bunch of things around and flatten common crate
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
/// Returns current unix time in ms (compatible with JS Date.now())
|
||||
pub fn now() -> u64 {
|
||||
use std::time::SystemTime;
|
||||
|
||||
SystemTime::now()
|
||||
.duration_since(SystemTime::UNIX_EPOCH)
|
||||
.expect("System time must be configured to be post Unix Epoch start; qed")
|
||||
.as_millis() as u64
|
||||
}
|
||||
Reference in New Issue
Block a user