summaryrefslogtreecommitdiff
path: root/ext/kv/lib.rs
diff options
context:
space:
mode:
authorDivy Srivastava <dj.srivastava23@gmail.com>2023-10-30 08:45:45 -0700
committerGitHub <noreply@github.com>2023-10-30 11:45:45 -0400
commit1acef755ca8a0a0433a98e4a66433c63ee0a3b09 (patch)
tree015ce439d800e8e35916d498de3780e6ee03e0df /ext/kv/lib.rs
parent02cc37e05494e576ea8e120b9fe21b447da9546b (diff)
chore: remove usage of chrono::Utc::now() (#20995)
Remove usage of Chrono's clock feature which pulls in iana-time-zone -> core-foundation
Diffstat (limited to 'ext/kv/lib.rs')
-rw-r--r--ext/kv/lib.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/kv/lib.rs b/ext/kv/lib.rs
index 20f774033..fb68596fa 100644
--- a/ext/kv/lib.rs
+++ b/ext/kv/lib.rs
@@ -6,6 +6,7 @@ mod interface;
mod proto;
pub mod remote;
pub mod sqlite;
+mod time;
use std::borrow::Cow;
use std::cell::RefCell;
@@ -14,7 +15,6 @@ use std::rc::Rc;
use base64::prelude::BASE64_URL_SAFE;
use base64::Engine;
-use chrono::Utc;
use codec::decode_key;
use codec::encode_key;
use deno_core::anyhow::Context;
@@ -610,7 +610,7 @@ async fn op_kv_atomic_write<DBH>(
where
DBH: DatabaseHandler + 'static,
{
- let current_timestamp = Utc::now().timestamp_millis() as u64;
+ let current_timestamp = time::utc_now().timestamp_millis() as u64;
let db = {
let state = state.borrow();
let resource =