Преглед на файлове

Merge pull request #46716 from akerouanton/fix-bad-condition

api: fix a nil check on the wrong var
Paweł Gronowski преди 1 година
родител
ревизия
dcc80204bc
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      api/server/router/container/container_routes.go

+ 1 - 1
api/server/router/container/container_routes.go

@@ -544,7 +544,7 @@ func (s *containerRouter) postContainersCreate(ctx context.Context, w http.Respo
 		}
 	}
 
-	if hostConfig != nil && versions.LessThan(version, "1.44") {
+	if config != nil && versions.LessThan(version, "1.44") {
 		if config.Healthcheck != nil {
 			// StartInterval was added in API 1.44
 			config.Healthcheck.StartInterval = 0