Skip to content

Commit

Permalink
resource/image: Fix "always false" condition
Browse files Browse the repository at this point in the history
Found using gocritic linter.
  • Loading branch information
quasilyte authored and bep committed Dec 10, 2018
1 parent c84f506 commit 2564189
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion resource/image.go
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ func parseImageConfig(config string) (imageConfig, error) {
if err != nil {
return c, err
}
if c.Quality < 1 && c.Quality > 100 {
if c.Quality < 1 || c.Quality > 100 {
return c, errors.New("quality ranges from 1 to 100 inclusive")
}
} else if part[0] == 'r' {
Expand Down

0 comments on commit 2564189

Please sign in to comment.