|  | @@ -53,27 +53,24 @@ type matcherEntry struct {
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  type MatcherGroup struct {
 |  |  type MatcherGroup struct {
 | 
											
												
													
														|  |  	count         uint32
 |  |  	count         uint32
 | 
											
												
													
														|  | -	fullMatchers  map[string]uint32
 |  | 
 | 
											
												
													
														|  | 
 |  | +	fullMatcher   FullMatcherGroup
 | 
											
												
													
														|  |  	domainMatcher DomainMatcherGroup
 |  |  	domainMatcher DomainMatcherGroup
 | 
											
												
													
														|  |  	otherMatchers []matcherEntry
 |  |  	otherMatchers []matcherEntry
 | 
											
												
													
														|  |  }
 |  |  }
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  func NewMatcherGroup() *MatcherGroup {
 |  |  func NewMatcherGroup() *MatcherGroup {
 | 
											
												
													
														|  | -	return &MatcherGroup{
 |  | 
 | 
											
												
													
														|  | -		count:        1,
 |  | 
 | 
											
												
													
														|  | -		fullMatchers: make(map[string]uint32),
 |  | 
 | 
											
												
													
														|  | -	}
 |  | 
 | 
											
												
													
														|  | 
 |  | +	return &MatcherGroup{}
 | 
											
												
													
														|  |  }
 |  |  }
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  func (g *MatcherGroup) Add(m Matcher) uint32 {
 |  |  func (g *MatcherGroup) Add(m Matcher) uint32 {
 | 
											
												
													
														|  | -	c := g.count
 |  | 
 | 
											
												
													
														|  |  	g.count++
 |  |  	g.count++
 | 
											
												
													
														|  | 
 |  | +	c := g.count
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  	switch tm := m.(type) {
 |  |  	switch tm := m.(type) {
 | 
											
												
													
														|  |  	case fullMatcher:
 |  |  	case fullMatcher:
 | 
											
												
													
														|  | -		g.fullMatchers[string(tm)] = c
 |  | 
 | 
											
												
													
														|  | 
 |  | +		g.fullMatcher.addMatcher(tm, c)
 | 
											
												
													
														|  |  	case domainMatcher:
 |  |  	case domainMatcher:
 | 
											
												
													
														|  | -		g.domainMatcher.Add(string(tm), c)
 |  | 
 | 
											
												
													
														|  | 
 |  | +		g.domainMatcher.addMatcher(tm, c)
 | 
											
												
													
														|  |  	default:
 |  |  	default:
 | 
											
												
													
														|  |  		g.otherMatchers = append(g.otherMatchers, matcherEntry{
 |  |  		g.otherMatchers = append(g.otherMatchers, matcherEntry{
 | 
											
												
													
														|  |  			m:  m,
 |  |  			m:  m,
 | 
											
										
											
												
													
														|  | @@ -85,7 +82,7 @@ func (g *MatcherGroup) Add(m Matcher) uint32 {
 | 
											
												
													
														|  |  }
 |  |  }
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  func (g *MatcherGroup) Match(pattern string) uint32 {
 |  |  func (g *MatcherGroup) Match(pattern string) uint32 {
 | 
											
												
													
														|  | -	if c, f := g.fullMatchers[pattern]; f {
 |  | 
 | 
											
												
													
														|  | 
 |  | +	if c := g.fullMatcher.Match(pattern); c > 0 {
 | 
											
												
													
														|  |  		return c
 |  |  		return c
 | 
											
												
													
														|  |  	}
 |  |  	}
 | 
											
												
													
														|  |  
 |  |  
 |