diff options
author | Heyang Zhou <zhy20000919@hotmail.com> | 2023-08-18 17:34:16 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-18 17:34:16 +0800 |
commit | c77c836a238ce683b21c12f88cd1101b930ce042 (patch) | |
tree | b69b2318f618d1b384dc168ab6652496d63e2f2c /ext/kv/lib.rs | |
parent | b5839eefcf02e62e9e77e8095f372ac06a523cba (diff) |
feat(ext/kv): key expiration (#20091)
Co-authored-by: Luca Casonato <hello@lcas.dev>
Diffstat (limited to 'ext/kv/lib.rs')
-rw-r--r-- | ext/kv/lib.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/ext/kv/lib.rs b/ext/kv/lib.rs index a781f4579..7164a700b 100644 --- a/ext/kv/lib.rs +++ b/ext/kv/lib.rs @@ -375,7 +375,7 @@ impl TryFrom<V8KvCheck> for KvCheck { } } -type V8KvMutation = (KvKey, String, Option<FromV8Value>); +type V8KvMutation = (KvKey, String, Option<FromV8Value>, Option<u64>); impl TryFrom<V8KvMutation> for KvMutation { type Error = AnyError; @@ -396,7 +396,11 @@ impl TryFrom<V8KvMutation> for KvMutation { ))) } }; - Ok(KvMutation { key, kind }) + Ok(KvMutation { + key, + kind, + expire_at: value.3, + }) } } |