summaryrefslogtreecommitdiff
path: root/lib/gitlab/checks/change_access.rb
diff options
context:
space:
mode:
authorJames Edwards-Jones <jedwardsjones@gitlab.com>2017-04-03 20:06:06 +0100
committerJames Edwards-Jones <jedwardsjones@gitlab.com>2017-04-03 20:06:06 +0100
commit9f4b8dba805915bd21d315f159035449f9f4bef0 (patch)
treed7e5564a80a01de9153aa1fa9143f0b80d69ad87 /lib/gitlab/checks/change_access.rb
parent35b719f60b21fbd09a1a2b4dc0d3f1e3e74e89e1 (diff)
downloadgitlab-ce-9f4b8dba805915bd21d315f159035449f9f4bef0.tar.gz
Clean up non TODO rubocop errors
Diffstat (limited to 'lib/gitlab/checks/change_access.rb')
-rw-r--r--lib/gitlab/checks/change_access.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/gitlab/checks/change_access.rb b/lib/gitlab/checks/change_access.rb
index 6f574a41727..07fd4024346 100644
--- a/lib/gitlab/checks/change_access.rb
+++ b/lib/gitlab/checks/change_access.rb
@@ -71,15 +71,15 @@ module Gitlab
def protected_tag_checks
return unless tag_protected?
- if forced_push?
- return "You are not allowed to force push protected tags." #TODO: Wording, 'not allowed to update proteted tags'?
+ if forced_push? #TODO: Verify if this should prevent all updates, and mention in UI and documentation
+ return "Protected tags cannot be updated."
end
if Gitlab::Git.blank_ref?(@newrev)
- return "You are not allowed to delete protected tags." #TODO: Wording, do these need to mention 'you' if the rule applies to everyone
+ return "Protected tags cannot be deleted."
end
- if !user_access.can_push_tag?(@tag_name)
+ unless user_access.can_push_tag?(@tag_name)
return "You are not allowed to create this tag as it is protected."
end
end