diff options
author | metamuffin <metamuffin@disroot.org> | 2025-06-02 22:50:17 +0200 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2025-06-02 22:50:17 +0200 |
commit | 472916ef1381e1fd2ff021e47fa36a993b44033a (patch) | |
tree | 2cab757c8d58119406dcb9dcdb0074784b758483 /src | |
parent | 5f6dfeada0158c815f0b7b474ec61c18db6af5db (diff) | |
download | isda-472916ef1381e1fd2ff021e47fa36a993b44033a.tar isda-472916ef1381e1fd2ff021e47fa36a993b44033a.tar.bz2 isda-472916ef1381e1fd2ff021e47fa36a993b44033a.tar.zst |
support query for key existance
Diffstat (limited to 'src')
-rw-r--r-- | src/worker_ws.rs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/worker_ws.rs b/src/worker_ws.rs index bf0bf7f..fa43721 100644 --- a/src/worker_ws.rs +++ b/src/worker_ws.rs @@ -265,8 +265,14 @@ impl State { continue 'taskloop; }; for (k, v) in &data { - if cdata.get(k) != Some(v) { - continue 'taskloop; + if v.is_null() { + if !cdata.contains_key(k) { + continue 'taskloop; + } + } else { + if cdata.get(k) != Some(v) { + continue 'taskloop; + } } } } |