Browse code

Fix client lib errors documentation.

Signed-off-by: David Calavera <david.calavera@gmail.com>

David Calavera authored on 2015/12/05 05:29:58
Showing 1 changed files
... ...
@@ -5,6 +5,7 @@ import (
5 5
 	"fmt"
6 6
 )
7 7
 
8
+// ErrConnectionFailed is a error raised when the connection between the client and the server failed.
8 9
 var ErrConnectionFailed = errors.New("Cannot connect to the Docker daemon. Is the docker daemon running on this host?")
9 10
 
10 11
 // imageNotFoundError implements an error returned when an image is not in the docker host.
... ...
@@ -17,7 +18,7 @@ func (i imageNotFoundError) Error() string {
17 17
 	return fmt.Sprintf("Image not found: %s", i.imageID)
18 18
 }
19 19
 
20
-// IsImageNotFound returns true if the error is caused
20
+// IsErrImageNotFound returns true if the error is caused
21 21
 // when an image is not found in the docker host.
22 22
 func IsErrImageNotFound(err error) bool {
23 23
 	_, ok := err.(imageNotFoundError)
... ...
@@ -34,7 +35,7 @@ func (u unauthorizedError) Error() string {
34 34
 	return u.cause.Error()
35 35
 }
36 36
 
37
-// IsUnauthorized returns true if the error is caused
37
+// IsErrUnauthorized returns true if the error is caused
38 38
 // when an the remote registry authentication fails
39 39
 func IsErrUnauthorized(err error) bool {
40 40
 	_, ok := err.(unauthorizedError)