lint code

This commit is contained in:
Javier Provecho Fernandez
2016-04-15 01:16:46 +02:00
parent 89f1adf0eb
commit 9e930b9bdd
17 changed files with 72 additions and 73 deletions

View File

@ -47,7 +47,7 @@ func WrapH(h http.Handler) HandlerFunc {
type H map[string]interface{}
// Allows type H to be used with xml.Marshal
// MarshalXML allows type H to be used with xml.Marshal
func (h H) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
start.Name = xml.Name{
Space: "",
@ -143,10 +143,9 @@ func resolveAddress(addr []string) string {
if port := os.Getenv("PORT"); len(port) > 0 {
debugPrint("Environment variable PORT=\"%s\"", port)
return ":" + port
} else {
debugPrint("Environment variable PORT is undefined. Using port :8080 by default")
return ":8080"
}
debugPrint("Environment variable PORT is undefined. Using port :8080 by default")
return ":8080"
case 1:
return addr[0]
default: