Browse Source

Fix return on ports when empty

Signed-off-by: Ulysses Souza <[email protected]>
Ulysses Souza 5 years ago
parent
commit
178ac40dba
1 changed files with 1 additions and 1 deletions
  1. 1 1
      utils/formatter/container.go

+ 1 - 1
utils/formatter/container.go

@@ -33,8 +33,8 @@ type portGroup struct {
 // PortsToStrings returns a human readable published ports
 func PortsToStrings(ports []containers.Port, fqdn string) []string {
 	groupMap := make(map[string]*portGroup)
+	result := []string{}
 	var (
-		result       []string
 		hostMappings []string
 		groupMapKeys []string
 	)