File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11package cmd
22
33import (
4- "errors"
54 "fmt"
65 "io"
76 "os"
@@ -41,18 +40,11 @@ func HealthchecksList(appID, procType string) error {
4140 }
4241
4342 fmt .Printf ("=== %s Healthchecks\n \n " , appID )
44- if procType == "" {
45- for proc , healthcheck := range config .Healthcheck {
46- fmt .Println (proc + ":" )
47- printHealthCheck (os .Stdout , * healthcheck )
48- }
43+ fmt .Println (procType + ":" )
44+ if healthcheck , found := config .Healthcheck [procType ]; found {
45+ printHealthCheck (os .Stdout , * healthcheck )
4946 } else {
50- fmt .Println (procType + ":" )
51- if healthcheck , found := config .Healthcheck [procType ]; found {
52- printHealthCheck (os .Stdout , * healthcheck )
53- } else {
54- return errors .New (appID + " doesn't have proctype" + procType )
55- }
47+ printHealthCheck (os .Stdout , api.Healthchecks {})
5648 }
5749
5850 return nil
You can’t perform that action at this time.
0 commit comments