1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Return an empty services list if no services are running

Signed-off-by: Ralf Sippl <ralf.sippl@gmail.com>
(cherry picked from commit c8e4e95db9)
Signed-off-by: Tibor Vass <tibor@docker.com>
This commit is contained in:
Ralf Sippl 2016-07-12 11:41:04 +02:00 committed by Tibor Vass
parent adfeccf06f
commit 18f1fc8349

View file

@ -654,7 +654,7 @@ func (c *Cluster) GetServices(options apitypes.ServiceListOptions) ([]types.Serv
return nil, err
}
var services []types.Service
services := []types.Service{}
for _, service := range r.Services {
services = append(services, convert.ServiceFromGRPC(*service))