summaryrefslogtreecommitdiffstats
path: root/adenosine-cli/src/lib.rs
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2022-11-04 19:16:27 -0700
committerBryan Newbold <bnewbold@robocracy.org>2022-11-04 19:16:27 -0700
commit05495ede3e4defac165a1f536dfe6d62fc181557 (patch)
tree104325f9fa5f7fe9abbae3ba0815253669d6c96b /adenosine-cli/src/lib.rs
parentbc8493998d90799551c5e0703bbb4a6e69d2478a (diff)
downloadadenosine-05495ede3e4defac165a1f536dfe6d62fc181557.tar.gz
adenosine-05495ede3e4defac165a1f536dfe6d62fc181557.zip
cli: basic CRUD bug fixes
Diffstat (limited to 'adenosine-cli/src/lib.rs')
-rw-r--r--adenosine-cli/src/lib.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/adenosine-cli/src/lib.rs b/adenosine-cli/src/lib.rs
index a136cea..cecbbe4 100644
--- a/adenosine-cli/src/lib.rs
+++ b/adenosine-cli/src/lib.rs
@@ -287,7 +287,10 @@ fn test_argfield() {
pub fn update_params_from_fields(fields: &[ArgField], params: &mut HashMap<String, String>) {
for f in fields.iter() {
if let ArgField::Query(ref k, ref v) = f {
- params.insert(k.to_string(), v.to_string());
+ match v {
+ Value::String(s) => params.insert(k.to_string(), s.to_string()),
+ _ => params.insert(k.to_string(), v.to_string()),
+ };
}
}
}