File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -1043,14 +1043,20 @@ impl<'a> Parser<'a> {
1043
1043
& mut self ,
1044
1044
input : Input < ' i > ,
1045
1045
) -> ParseResult < ( bool , HostInternal , Input < ' i > ) > {
1046
- let ( has_host, host_str, remaining) = Parser :: file_host ( input) ?;
1046
+ let has_host;
1047
+ let ( _, host_str, remaining) = Parser :: file_host ( input) ?;
1047
1048
let host = if host_str. is_empty ( ) {
1049
+ has_host = false ;
1048
1050
HostInternal :: None
1049
1051
} else {
1050
1052
match Host :: parse ( & host_str) ? {
1051
- Host :: Domain ( ref d) if d == "localhost" => HostInternal :: None ,
1053
+ Host :: Domain ( ref d) if d == "localhost" => {
1054
+ has_host = false ;
1055
+ HostInternal :: None
1056
+ }
1052
1057
host => {
1053
1058
write ! ( & mut self . serialization, "{}" , host) . unwrap ( ) ;
1059
+ has_host = true ;
1054
1060
host. into ( )
1055
1061
}
1056
1062
}
You can’t perform that action at this time.
0 commit comments