diff options
author | James Edwards-Jones <jedwardsjones@gitlab.com> | 2017-04-03 20:06:06 +0100 |
---|---|---|
committer | James Edwards-Jones <jedwardsjones@gitlab.com> | 2017-04-03 20:06:06 +0100 |
commit | 9f4b8dba805915bd21d315f159035449f9f4bef0 (patch) | |
tree | d7e5564a80a01de9153aa1fa9143f0b80d69ad87 /lib | |
parent | 35b719f60b21fbd09a1a2b4dc0d3f1e3e74e89e1 (diff) | |
download | gitlab-ce-9f4b8dba805915bd21d315f159035449f9f4bef0.tar.gz |
Clean up non TODO rubocop errors
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/checks/change_access.rb | 8 | ||||
-rw-r--r-- | lib/gitlab/import_export/relation_factory.rb | 2 |
2 files changed, 5 insertions, 5 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 diff --git a/lib/gitlab/import_export/relation_factory.rb b/lib/gitlab/import_export/relation_factory.rb index d44563333a5..9d269c5d384 100644 --- a/lib/gitlab/import_export/relation_factory.rb +++ b/lib/gitlab/import_export/relation_factory.rb @@ -7,7 +7,7 @@ module Gitlab triggers: 'Ci::Trigger', builds: 'Ci::Build', hooks: 'ProjectHook', - merge_access_levels: 'ProtectedBranch::MergeAccessLevel', + merge_access_levels: 'ProtectedBranch::MergeAccessLevel', #TODO: Tags push_access_levels: 'ProtectedBranch::PushAccessLevel', labels: :project_labels, priorities: :label_priorities, |