mastersrv: Go to RawValue directly

Instead of going through `String`.
This commit is contained in:
heinrich5991 2023-09-08 11:03:07 +02:00
parent ee1b8baab5
commit cbdd83f790

View file

@ -718,8 +718,7 @@ fn handle_register(
let info = i.as_object().ok_or("register info must be an object")?;
// Normalize the JSON to strip any spaces etc.
let raw_info = json::to_string(&info).unwrap();
Ok(json::value::RawValue::from_string(raw_info).unwrap())
Ok(json::value::to_raw_value(&info).unwrap())
})
.transpose()?;