Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
admpub committed Sep 23, 2024
1 parent c415656 commit 68de5f0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion subdomains/subdomains.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (

"github.com/admpub/log"

"github.com/webx-top/com"
"github.com/webx-top/echo"
"github.com/webx-top/echo/engine"
"github.com/webx-top/echo/engine/fasthttp"
Expand Down Expand Up @@ -120,7 +121,7 @@ func (s *Subdomains) Add(name string, e *echo.Echo) *Subdomains {
for _, host := range hosts {
if _, ok := s.Hosts[host]; !ok {
s.Hosts[host] = []string{name}
} else {
} else if !com.InSlice(name, s.Hosts[host]) {
s.Hosts[host] = append(s.Hosts[host], name)
}
}
Expand Down

0 comments on commit 68de5f0

Please sign in to comment.