Merge pull request #968 from JasonLG1979/silence-compiler-warning

Silence compiler warning
This commit is contained in:
Roderick van Domburg 2022-03-04 11:56:32 +01:00 committed by GitHub
commit dfa48562c4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -163,12 +163,7 @@ fn split_uri(s: &str) -> Option<impl Iterator<Item = &'_ str>> {
};
let rest = rest.trim_end_matches(sep);
let mut split = rest.split(sep);
#[cfg(debug_assertions)]
if rest.is_empty() {
assert_eq!(split.next(), Some(""));
}
let split = rest.split(sep);
Some(iter::once(scheme).chain(split))
}