diff --git a/app/views/projects/branches/_branch.html.haml b/app/views/projects/branches/_branch.html.haml index 835a6ac820d2c8e5c0ea5f534378c5eb69dc4ba1..dad993a61a565f281b8ef8c51bfa1e2ee20bae06 100644 --- a/app/views/projects/branches/_branch.html.haml +++ b/app/views/projects/branches/_branch.html.haml @@ -77,7 +77,7 @@ - else %button{ class: "btn btn-remove remove-row js-ajax-loading-spinner has-tooltip disabled", disabled: true, - title: s_('Branches|Only a project master or owner can delete a protected branch') } + title: s_('Branches|Only a project maintainer or owner can delete a protected branch') } = icon("trash-o") - else = link_to project_branch_path(@project, branch.name), diff --git a/lib/gitlab/checks/change_access.rb b/lib/gitlab/checks/change_access.rb index e211475dc2868b819ace11ce80813f0ce5d9c5b8..b6fc2952984d32701d34c753140e591819d098f1 100644 --- a/lib/gitlab/checks/change_access.rb +++ b/lib/gitlab/checks/change_access.rb @@ -7,7 +7,7 @@ module Gitlab push_code: 'You are not allowed to push code to this project.', delete_default_branch: 'The default branch of a project cannot be deleted.', force_push_protected_branch: 'You are not allowed to force push code to a protected branch on this project.', - non_master_delete_protected_branch: 'You are not allowed to delete protected branches from this project. Only a project master or owner can delete a protected branch.', + non_master_delete_protected_branch: 'You are not allowed to delete protected branches from this project. Only a project maintainer or owner can delete a protected branch.', non_web_delete_protected_branch: 'You can only delete protected branches using the web interface.', merge_protected_branch: 'You are not allowed to merge code into protected branches on this project.', push_protected_branch: 'You are not allowed to push code to protected branches on this project.', diff --git a/locale/gitlab.pot b/locale/gitlab.pot index ac24d90e5ac7d5d49dbd2c6b8c33939a694b5ef9..0cf4fde614d5e4fafb99639d197595be0625cf45 100644 --- a/locale/gitlab.pot +++ b/locale/gitlab.pot @@ -833,7 +833,7 @@ msgstr "" msgid "Branches|Once you confirm and press %{delete_protected_branch}, it cannot be undone or recovered." msgstr "" -msgid "Branches|Only a project master or owner can delete a protected branch" +msgid "Branches|Only a project maintainer or owner can delete a protected branch" msgstr "" msgid "Branches|Overview" diff --git a/spec/lib/gitlab/checks/change_access_spec.rb b/spec/lib/gitlab/checks/change_access_spec.rb index 02afb030ea7ae6211dad186d8800d906413b9e85..4342e9b5088d43242407969371aac6c041e835a0 100644 --- a/spec/lib/gitlab/checks/change_access_spec.rb +++ b/spec/lib/gitlab/checks/change_access_spec.rb @@ -52,7 +52,7 @@ describe Gitlab::Checks::ChangeAccess do context 'with protected tag' do let!(:protected_tag) { create(:protected_tag, project: project, name: 'v*') } - context 'as master' do + context 'as maintainer' do before do project.add_master(user) end @@ -138,7 +138,7 @@ describe Gitlab::Checks::ChangeAccess do context 'if the user is not allowed to delete protected branches' do it 'raises an error' do - expect { subject.exec }.to raise_error(Gitlab::GitAccess::UnauthorizedError, 'You are not allowed to delete protected branches from this project. Only a project master or owner can delete a protected branch.') + expect { subject.exec }.to raise_error(Gitlab::GitAccess::UnauthorizedError, 'You are not allowed to delete protected branches from this project. Only a project maintainer or owner can delete a protected branch.') end end