Skip to content
This repository has been archived by the owner on Sep 14, 2023. It is now read-only.

Commit

Permalink
🙏 Try to remove some to_string and see how compiler says
Browse files Browse the repository at this point in the history
  • Loading branch information
wdv4758h committed Jul 4, 2018
1 parent 3a35e1a commit c01aa15
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -441,10 +441,10 @@ impl<'a> TryFrom<HyperJsonValue<'a>> for PyObject {
Ok(ret?.to_object(*v.py))
}
serde_json::Value::Object(ref o) => {
let ret: Result<BTreeMap<String, PyObject>, _> = o
let ret: Result<BTreeMap<&String, PyObject>, _> = o
.iter()
.map(|(k, x)| {
let key = k.to_string();
let key = k;
let value =
HyperJsonValue::new(v.py, x, v.parse_float, v.parse_int).try_into();
match value {
Expand Down

0 comments on commit c01aa15

Please sign in to comment.