code: func (c *CORS) isOriginAllowed(origin string) (allowed bool) {
  	for _, allowedOriginPattern := range c.allowOriginPatterns {
  		allowed, _ = regexp.MatchString(allowedOriginPattern, origin)
  		if allowed {
  			return
  		}
  	}
  	return
  }
docs: // isOriginAllowed returns true if origin matches an allowed origin pattern.