From eb5462256831e930ff56c8f1e63c392c4fe216fd Mon Sep 17 00:00:00 2001 From: Satnam Singh Date: Mon, 22 Sep 2014 14:41:54 -0700 Subject: [PATCH 1/2] Fix a minor typo in the README.md file. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c3dc9c1e..1d865fae 100644 --- a/README.md +++ b/README.md @@ -134,4 +134,4 @@ cAdvisor aims to improve the resource usage and performance characteristics of r ## Community -Contributions, questions, and comments are all welcomed and encouraged! cAdvisor developers hand out in [#google-containers](http://webchat.freenode.net/?channels=google-containers) room on freenode.net. We also have the [google-containers Google Groups mailing list](https://groups.google.com/forum/#!forum/google-containers). +Contributions, questions, and comments are all welcomed and encouraged! cAdvisor developers hang out in [#google-containers](http://webchat.freenode.net/?channels=google-containers) room on freenode.net. We also have the [google-containers Google Groups mailing list](https://groups.google.com/forum/#!forum/google-containers). From 87768a047cc4ea16cd031e47ae9c9272f870adc5 Mon Sep 17 00:00:00 2001 From: Satnam Singh Date: Mon, 22 Sep 2014 15:20:14 -0700 Subject: [PATCH 2/2] Minor Go-style suggeston: move decode and error assignment into if clause check. --- api/handler.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/api/handler.go b/api/handler.go index 56ab8a7d..b45e74e5 100644 --- a/api/handler.go +++ b/api/handler.go @@ -172,8 +172,7 @@ func getContainerInfoRequest(body io.ReadCloser) (*info.ContainerInfoRequest, er query.NumStats = 64 decoder := json.NewDecoder(body) - err := decoder.Decode(&query) - if err != nil && err != io.EOF { + if err := decoder.Decode(&query); err != nil && err != io.EOF { return nil, fmt.Errorf("unable to decode the json value: %s", err) }