diff --git a/changelogs/fragments/4496-remove-deprecated-method-in-gitlab-branch-module.yml b/changelogs/fragments/4496-remove-deprecated-method-in-gitlab-branch-module.yml new file mode 100644 index 0000000000..07329367e7 --- /dev/null +++ b/changelogs/fragments/4496-remove-deprecated-method-in-gitlab-branch-module.yml @@ -0,0 +1,2 @@ +bugfixes: + - git_branch - remove deprecated and unnecessary branch ``unprotect`` method (https://github.com/ansible-collections/community.general/pull/4496). diff --git a/plugins/modules/source_control/gitlab/gitlab_branch.py b/plugins/modules/source_control/gitlab/gitlab_branch.py index ce71a00a9b..8707e6453a 100644 --- a/plugins/modules/source_control/gitlab/gitlab_branch.py +++ b/plugins/modules/source_control/gitlab/gitlab_branch.py @@ -110,7 +110,6 @@ class GitlabBranch(object): return self.project.branches.create({'branch': branch, 'ref': ref_branch}) def delete_branch(self, branch): - branch.unprotect() return branch.delete()