diff options
author | Kamil Trzcinski <ayufan@ayufan.eu> | 2016-02-11 21:36:15 +0300 |
---|---|---|
committer | Kamil Trzcinski <ayufan@ayufan.eu> | 2016-02-11 21:36:15 +0300 |
commit | 8166163d39f1f972b2bea2817bdc78cc0777faa3 (patch) | |
tree | fa41836f32a4368eaf1b1e8c15c6e029a76ee496 /domain_config.go | |
parent | 3732867a8f79171e2d5aefb8ceaa4b887fbbaf72 (diff) |
Move most of configuration to appConfig
Diffstat (limited to 'domain_config.go')
-rw-r--r-- | domain_config.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/domain_config.go b/domain_config.go index d384ef67..e0f00cc4 100644 --- a/domain_config.go +++ b/domain_config.go @@ -17,14 +17,14 @@ type domainsConfig struct { Domains []domainConfig } -func (c *domainConfig) Valid() bool { +func (c *domainConfig) Valid(rootDomain string) bool { if c.Domain == "" { return false } // TODO: better sanitize domain domain := strings.ToLower(c.Domain) - rootDomain := "." + strings.ToLower(*pagesDomain) + rootDomain = "." + rootDomain return !strings.HasSuffix(domain, rootDomain) } |