(left: &str, right: &str)
| 171 | } |
| 172 | |
| 173 | fn host_patterns_overlap(left: &str, right: &str) -> bool { |
| 174 | let left = normalize_host(left); |
| 175 | let right = normalize_host(right); |
| 176 | if left.is_empty() || right.is_empty() { |
| 177 | return false; |
| 178 | } |
| 179 | left == right || host_pattern_covers(&left, &right) || host_pattern_covers(&right, &left) |
| 180 | } |
| 181 | |
| 182 | fn host_pattern_covers(pattern: &str, host: &str) -> bool { |
| 183 | let pattern_labels: Vec<&str> = pattern.split('.').collect(); |
no test coverage detected