mirror of
https://github.com/interviewstreet/go-jira.git
synced 2025-04-19 12:02:20 +02:00
Merge pull request #51 from pmoncadaisla/fix-get-user
Fix User.GET() method
This commit is contained in:
commit
9de4f8cf7e
2
user.go
2
user.go
@ -31,7 +31,7 @@ type User struct {
|
|||||||
//
|
//
|
||||||
// JIRA API docs: https://docs.atlassian.com/jira/REST/cloud/#api/2/user-getUser
|
// JIRA API docs: https://docs.atlassian.com/jira/REST/cloud/#api/2/user-getUser
|
||||||
func (s *UserService) Get(username string) (*User, *Response, error) {
|
func (s *UserService) Get(username string) (*User, *Response, error) {
|
||||||
apiEndpoint := fmt.Sprintf("/rest/api/2/user/%s", username)
|
apiEndpoint := fmt.Sprintf("/rest/api/2/user?username=%s", username)
|
||||||
req, err := s.client.NewRequest("GET", apiEndpoint, nil)
|
req, err := s.client.NewRequest("GET", apiEndpoint, nil)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, nil, err
|
return nil, nil, err
|
||||||
|
Loading…
x
Reference in New Issue
Block a user