mirror of
https://github.com/status-im/PyGithub.git
synced 2026-08-31 10:51:14 +00:00
Correct URL for assignees on PRs (#1296)
The URL that was used for POST/DELETE when adding and removing assignees was the PR itself, when it should be the issue_url. Fixes #1294
This commit is contained in:
@@ -804,7 +804,7 @@ class PullRequest(github.GithubObject.CompletableGithubObject):
|
||||
post_parameters = {"assignees": [assignee.login if isinstance(assignee, github.NamedUser.NamedUser) else assignee for assignee in assignees]}
|
||||
headers, data = self._requester.requestJsonAndCheck(
|
||||
"POST",
|
||||
self.url + "/assignees",
|
||||
self.issue_url + "/assignees",
|
||||
input=post_parameters
|
||||
)
|
||||
self._useAttributes(data)
|
||||
@@ -819,7 +819,7 @@ class PullRequest(github.GithubObject.CompletableGithubObject):
|
||||
post_parameters = {"assignees": [assignee.login if isinstance(assignee, github.NamedUser.NamedUser) else assignee for assignee in assignees]}
|
||||
headers, data = self._requester.requestJsonAndCheck(
|
||||
"DELETE",
|
||||
self.url + "/assignees",
|
||||
self.issue_url + "/assignees",
|
||||
input=post_parameters
|
||||
)
|
||||
self._useAttributes(data)
|
||||
|
||||
Reference in New Issue
Block a user