summaryrefslogtreecommitdiff
path: root/lib/ci
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2016-12-19 19:14:21 +0800
committerLin Jen-Shin <godfat@godfat.org>2016-12-19 19:14:21 +0800
commitec003d9eb338f9172696f5540637e759a93f9fcf (patch)
tree139f727438ca53f1d5b087da4269aca62e9f2be8 /lib/ci
parentfb23153343f274a29cba1023759f675aaf64251a (diff)
downloadgitlab-ce-ec003d9eb338f9172696f5540637e759a93f9fcf.tar.gz
Prefer unless over if not
Feedback: https://gitlab.com/gitlab-org/gitlab-ce/builds/7606797
Diffstat (limited to 'lib/ci')
-rw-r--r--lib/ci/api/helpers.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ci/api/helpers.rb b/lib/ci/api/helpers.rb
index 51b05aa0cb6..62c10c3b753 100644
--- a/lib/ci/api/helpers.rb
+++ b/lib/ci/api/helpers.rb
@@ -15,7 +15,7 @@ module Ci
def authenticate_build!(build)
not_found! unless build
- forbidden! if !build_token_valid?(build)
+ forbidden! unless build_token_valid?(build)
validate_build!(build)
end