kopia lustrzana https://github.com/Langenfeld/py-gitea
hacky solution to retrieve tickets of exactly one user of a repo
rodzic
c1acdfb60c
commit
25f6acad8a
|
@ -266,7 +266,9 @@ class Issue(GiteaApiObject):
|
||||||
|
|
||||||
def get_comments(self) -> List[GiteaApiObject]:
|
def get_comments(self) -> List[GiteaApiObject]:
|
||||||
results = self.gitea.requests_get(Issue.GET_COMMENTS%(self.owner.username, self.repo))
|
results = self.gitea.requests_get(Issue.GET_COMMENTS%(self.owner.username, self.repo))
|
||||||
return [Comment.parse_request(self.gitea, result) for result in results]
|
allProjectComments = [Comment.parse_request(self.gitea, result) for result in results]
|
||||||
|
# Comparing the issue id with the URL seems to be the only (!) way to get to the comments of one issue
|
||||||
|
return [comment for comment in allProjectComments if comment.issue_url.endswith("/" + str(self.number))]
|
||||||
|
|
||||||
|
|
||||||
class Branch(GiteaApiObject):
|
class Branch(GiteaApiObject):
|
||||||
|
|
Ładowanie…
Reference in New Issue