diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2021-06-28 00:19:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-28 00:19:40 +0200 |
commit | 9e875b2a2353eb4f3c6343a22e19c01276571cf6 (patch) | |
tree | 0b8f5233c2e372821dec75d0b2e5b908d0abde18 /runtime/ops/http.rs | |
parent | 098a7c8886a5be80f2acb4ed81365498a228ca0a (diff) |
fix(http): remove unwrap() in HTTP bindings (#11130)
Diffstat (limited to 'runtime/ops/http.rs')
-rw-r--r-- | runtime/ops/http.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/runtime/ops/http.rs b/runtime/ops/http.rs index cd1ac9242..01658c802 100644 --- a/runtime/ops/http.rs +++ b/runtime/ops/http.rs @@ -222,7 +222,7 @@ async fn op_http_request_next( } else { Cow::Owned(conn_resource.addr.to_string()) }; - let path = req.uri().path_and_query().unwrap(); + let path = req.uri().path_and_query().map_or("/", |p| p.as_str()); format!("{}://{}{}", scheme, host, path) }; |