1
0
mirror of https://github.com/interviewstreet/go-jira.git synced 2025-03-19 20:57:47 +02:00

Remove update fields, because this is more like edit issue and this method was not fully complete

This commit is contained in:
Andy Grunwald 2016-03-27 13:53:15 +02:00
parent 1d62c4bf25
commit bc2f1e8320

View File

@ -249,29 +249,7 @@ func (s *IssueService) Create(issue *Issue) (*Issue, *http.Response, error) {
return responseIssue, resp, nil
}
func (s *IssueService) UpdateFields(issueID string, fields map[string]string) (*Issue, *http.Response, error) {
apiEndpoint := fmt.Sprintf("rest/api/2/issue/%s", issueID)
type FieldsParams struct {
Fields map[string]string `json:"fields"`
}
params := FieldsParams{
Fields: fields,
}
req, err := s.client.NewRequest("PUT", apiEndpoint, params)
if err != nil {
return nil, nil, err
}
responseIssue := new(Issue)
resp, _ := s.client.Do(req, responseIssue)
return responseIssue, resp, nil
}
func (s *IssueService) AddComment(issueID string, comment string) (*Issue, *http.Response, error) {
func (s *IssueService) AddComment(issueID string, comment string) (*Issue, *http.Response, error) {
apiEndpoint := fmt.Sprintf("rest/api/2/issue/%s/comment", issueID)
type CommentBody struct {