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 b9168ba commit 32f7667Copy full SHA for 32f7667
graphql_client_web/src/lib.rs
@@ -138,7 +138,7 @@ impl Client {
138
JsFuture::from(text_promise).map_err(|_| ClientError::ResponseText)
139
})
140
.and_then(|text| {
141
- let response_text = text.as_string().unwrap_or_else(|| String::new());
+ let response_text = text.as_string().unwrap_or_default();
142
debug!("response text as string: {:?}", response_text);
143
serde_json::from_str(&response_text).map_err(|_| ClientError::ResponseShape)
144
graphql_client_web/tests/web.rs
@@ -45,7 +45,6 @@ fn test_germany() -> impl Future<Item = (), Error = JsValue> {
45
46
.map_err(|err| {
47
panic!("{:?}", err);
48
- JsValue::NULL
49
50
}
51
0 commit comments