chore: Merge branch v1 into v2 (#702)

This commit is contained in:
Fabian-Lars
2023-11-14 01:50:13 +01:00
committed by GitHub
parent d4d1633c4d
commit 251852ccbc
42 changed files with 1663 additions and 5522 deletions
+8 -1
View File
@@ -21,7 +21,14 @@ pub(crate) fn to_json(v: MySqlValueRef) -> Result<JsonValue, Error> {
JsonValue::Null
}
}
"FLOAT" | "DOUBLE" => {
"FLOAT" => {
if let Ok(v) = ValueRef::to_owned(&v).try_decode::<f32>() {
JsonValue::from(v)
} else {
JsonValue::Null
}
}
"DOUBLE" => {
if let Ok(v) = ValueRef::to_owned(&v).try_decode::<f64>() {
JsonValue::from(v)
} else {