aboutsummaryrefslogtreecommitdiff
path: root/scope.go
diff options
context:
space:
mode:
Diffstat (limited to 'scope.go')
-rw-r--r--scope.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/scope.go b/scope.go
index de909f4..a2c06b6 100644
--- a/scope.go
+++ b/scope.go
@@ -57,6 +57,9 @@ func (m URLPrefixMap) Add(uri *url.URL) {
func (m URLPrefixMap) Contains(uri *url.URL) bool {
s := strings.TrimPrefix(uri.Host, "www.")
+ if _, ok := m[s]; ok {
+ return true
+ }
for _, p := range strings.Split(uri.Path, "/") {
if p == "" {
continue