1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

registry/registry.go: simplify logical expression

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
This commit is contained in:
Alexander Morozov 2015-11-17 16:12:11 -08:00
parent e2417e3e92
commit 90e2459ecb

View file

@ -221,9 +221,7 @@ func ContinueOnError(err error) bool {
case *client.UnexpectedHTTPResponseError: case *client.UnexpectedHTTPResponseError:
return true return true
case error: case error:
if val := strings.Contains(err.Error(), strings.ToLower(syscall.ENOSPC.Error())); val { return !strings.Contains(err.Error(), strings.ToLower(syscall.ENOSPC.Error()))
return false
}
} }
// let's be nice and fallback if the error is a completely // let's be nice and fallback if the error is a completely
// unexpected one. // unexpected one.