Skip to content

Commit

Permalink
Tested more models.
Browse files Browse the repository at this point in the history
  • Loading branch information
Knucklessg1 committed May 7, 2024
1 parent e6c8236 commit f64441f
Show file tree
Hide file tree
Showing 3 changed files with 612 additions and 459 deletions.
6 changes: 3 additions & 3 deletions gitlab_api/gitlab_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -2048,13 +2048,13 @@ def protect_branch(self, **kwargs):

if protected_branch.data:
response = self._session.post(url=f'{self.url}/projects/{protected_branch.project_id}'
f'/protected_branches{protected_branch.branch_filter}',
f'/protected_branches{protected_branch.api_parameters}',
headers=self.headers,
data=json.dumps(protected_branch.data, indent=2),
verify=self.verify)
else:
response = self._session.post(url=f'{self.url}/projects/{protected_branch.project_id}'
f'/protected_branches{protected_branch.branch_filter}',
f'/protected_branches{protected_branch.api_parameters}',
headers=self.headers, verify=self.verify)
return response

Expand Down Expand Up @@ -2530,7 +2530,7 @@ def get_project_runners(self, **kwargs):
raise MissingParameterError
try:
response = self._session.get(url=f'{self.url}/projects/{runner.project_id}'
f'/runners{runner.runner_filter}',
f'/runners{runner.api_parameters}',
headers=self.headers,
verify=self.verify)
except ValidationError as e:
Expand Down
Loading

0 comments on commit f64441f

Please sign in to comment.