Very minor clean-ups (import re-ordering by automated tooling) (#28)

This commit is contained in:
Michael Vorburger ⛑️
2021-12-12 01:20:19 +01:00
committed by GitHub
parent ca55bde751
commit 1f5ac0b49d
9 changed files with 31 additions and 27 deletions
+5 -8
View File
@@ -2,11 +2,12 @@ package server
import (
"encoding/json"
"github.com/gorilla/mux"
"github.com/sirupsen/logrus"
"net/http"
"strings"
"sync"
"github.com/gorilla/mux"
"github.com/sirupsen/logrus"
)
func init() {
@@ -134,16 +135,12 @@ func (r *routesImpl) FindBackendForServerAddress(serverAddress string) (string,
address := strings.ToLower(addressParts[0])
if r.mappings == nil {
return r.defaultRoute, address
} else {
if r.mappings != nil {
if route, exists := r.mappings[address]; exists {
return route, address
} else {
return r.defaultRoute, address
}
}
return r.defaultRoute, address
}
func (r *routesImpl) GetMappings() map[string]string {