Browse Source

SizeRW & SizeRootFs omitted if empty in /container/json call

Signed-off-by: Antonio Murdaca <runcom@linux.com>
Antonio Murdaca 10 years ago
parent
commit
6945ac2d02
2 changed files with 2 additions and 4 deletions
  1. 2 2
      api/types/types.go
  2. 0 2
      integration-cli/docker_api_containers_test.go

+ 2 - 2
api/types/types.go

@@ -107,8 +107,8 @@ type Container struct {
 	Command    string
 	Created    int
 	Ports      []Port
-	SizeRw     int
-	SizeRootFs int
+	SizeRw     int `json:",omitempty"`
+	SizeRootFs int `json:",omitempty"`
 	Labels     map[string]string
 	Status     string
 }

+ 0 - 2
integration-cli/docker_api_containers_test.go

@@ -71,8 +71,6 @@ func (s *DockerSuite) TestContainerApiGetJSONNoFieldsOmitted(c *check.C) {
 		"Command",
 		"Created",
 		"Ports",
-		"SizeRw",
-		"SizeRootFs",
 		"Labels",
 		"Status",
 	}