Merge pull request #18050 from LK4D4/simple_err_registry

registry/registry.go: simplify logical expression
This commit is contained in:
Antonio Murdaca 2015-11-18 11:51:55 +01:00
commit 927d0be4d8

View file

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