go-gitea / go-sdk

Gitea: Golang SDK, moved to https://gitea.com/gitea/go-sdk
http://gitea.io
MIT License
29 stars 53 forks source link

ListPullRequestsOptions does not work? #161

Open quantonganh opened 5 years ago

quantonganh commented 5 years ago

https://github.com/go-gitea/go-sdk/blob/7d954d775498ad54b89860eb587f9692f68a1875/gitea/pull.go#L77

How does this work?

https://github.com/go-gitea/go-sdk/blob/7d954d775498ad54b89860eb587f9692f68a1875/gitea/gitea.go#L109

https://github.com/go-gitea/go-sdk/blob/7d954d775498ad54b89860eb587f9692f68a1875/gitea/gitea.go#L73

https://github.com/go-gitea/go-sdk/blob/7d954d775498ad54b89860eb587f9692f68a1875/gitea/gitea.go#L55

You passed body as a JSON to a GET request and expect it will be converted to a query string?

lunny commented 5 years ago

I think give a body param to a GET request is not a normal usage. But I have tested tea pulls, see https://github.com/go-gitea/tea, it works.

quantonganh commented 5 years ago

@lunny Have you tried tea pulls with a repo which has no open pull requests? https://github.com/go-gitea/tea/issues/17