aboutsummaryrefslogtreecommitdiff
path: root/src/web
diff options
context:
space:
mode:
Diffstat (limited to 'src/web')
-rw-r--r--src/web/web_server.rs5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/web/web_server.rs b/src/web/web_server.rs
index e4d15872..73aa6648 100644
--- a/src/web/web_server.rs
+++ b/src/web/web_server.rs
@@ -77,10 +77,7 @@ fn authority_to_host(authority: &str) -> Result<&str, Error> {
let split = match first_char {
'[' => {
let mut iter = iter.skip_while(|(_, c)| c != &']');
- iter.next().ok_or(Error::BadRequest(format!(
- "Authority {} has an illegal format",
- authority
- )))?;
+ iter.next().expect("Authority parsing logic error");
iter.next()
}
_ => iter.skip_while(|(_, c)| c != &':').next(),