We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e1fc99d commit c60d65cCopy full SHA for c60d65c
src/serializers/type_serializers/literal.rs
@@ -89,7 +89,7 @@ impl LiteralSerializer {
89
if let Ok(py_str) = value.downcast::<PyString>() {
90
let s = py_str.to_str()?;
91
if self.expected_str.contains(s) {
92
- return Ok(OutputValue::OkStr(py_str.clone()));
+ return Ok(OutputValue::OkStr(PyString::new_bound(value.py(), s)));
93
}
94
95
0 commit comments