From 14ac96e7de31aa07acb2c6f41dc6671d1408ccb2 Mon Sep 17 00:00:00 2001 From: Amit Upadhyay Date: Sat, 18 May 2024 23:14:21 +0530 Subject: [PATCH] sending query string to wasm --- fastn-ds/src/lib.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/fastn-ds/src/lib.rs b/fastn-ds/src/lib.rs index 85391fa9a8..1703b6a7fe 100644 --- a/fastn-ds/src/lib.rs +++ b/fastn-ds/src/lib.rs @@ -400,6 +400,12 @@ impl DocumentStore { let wasm_file = wasm_file.split_once(".wasm").unwrap().0; let module = self.get_wasm(format!("{wasm_file}.wasm").as_str()).await?; + let wasm_url = if req.query_string().is_empty() { + wasm_url + } else { + format!("{wasm_url}/?{}", req.query_string()) + }; + Ok(fastn_ds::wasm::process_http_request( ft_sys_shared::Request { uri: wasm_url,