Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/app.go
diff options
context:
space:
mode:
authorJacob Vosmaer <jacob@gitlab.com>2018-03-22 19:26:33 +0300
committerJacob Vosmaer <jacob@gitlab.com>2018-03-22 19:26:33 +0300
commit4f6fa0e5aab3bcf6e7b510f1678c83d420e05cba (patch)
treeba539af17dd7a071185152b321dff66753b1d19c /app.go
parent5987070946907a8d3411869ca166fd192d261b65 (diff)
Rename 'domains' type to 'domainMap'
Diffstat (limited to 'app.go')
-rw-r--r--app.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/app.go b/app.go
index 3a032a59..ef436401 100644
--- a/app.go
+++ b/app.go
@@ -29,20 +29,20 @@ var (
type theApp struct {
appConfig
- domains domains
+ dm domainMap
lock sync.RWMutex
Artifact *artifact.Artifact
}
func (a *theApp) isReady() bool {
- return a.domains != nil
+ return a.dm != nil
}
func (a *theApp) domain(host string) *domain {
host = strings.ToLower(host)
a.lock.RLock()
defer a.lock.RUnlock()
- domain, _ := a.domains[host]
+ domain, _ := a.dm[host]
return domain
}
@@ -157,10 +157,10 @@ func (a *theApp) ServeProxy(ww http.ResponseWriter, r *http.Request) {
a.serveContent(ww, r, https)
}
-func (a *theApp) UpdateDomains(domains domains) {
+func (a *theApp) UpdateDomains(dm domainMap) {
a.lock.Lock()
defer a.lock.Unlock()
- a.domains = domains
+ a.dm = dm
}
func (a *theApp) Run() {