diff --git a/cli/command/system/version.go b/cli/command/system/version.go index 712f0a934c..952c4d72ab 100644 --- a/cli/command/system/version.go +++ b/cli/command/system/version.go @@ -33,7 +33,7 @@ Client:{{if ne .Platform.Name ""}} {{.Platform.Name}}{{end}} Context: {{.Context}} {{- end}} -{{- if .ServerOK}}{{with .Server}} +{{- if ne .Server nil}}{{with .Server}} Server:{{if ne .Platform.Name ""}} {{.Platform.Name}}{{end}} {{- range $component := .Components}} @@ -80,12 +80,6 @@ type clientVersion struct { Context string } -// ServerOK returns true when the client could connect to the docker server -// and parse the information received. It returns false otherwise. -func (v versionInfo) ServerOK() bool { - return v.Server != nil -} - // NewVersionCommand creates a new cobra.Command for `docker version` func NewVersionCommand(dockerCli command.Cli) *cobra.Command { var opts versionOptions