Skip to content

Commit

Permalink
fix: correct some issues
Browse files Browse the repository at this point in the history
  • Loading branch information
saman2000hoseini committed Jul 12, 2023
1 parent db21323 commit 8c1a02e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/webhook-proxy/handler/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func (p *Proxy) proxyRequest(txt string, url string) bool {

func generateElementText(req *request.Jira) string {
return fmt.Sprintf(
"Request Type: %s\nRequest Summary: %s\nIssuer: %s\nURL: %s",
req.Issue.Fields.IssueType.Name, req.Issue.Fields.Summary, req.User.Name,
"Type: %s\nSummary: %s\nIssuer: %s\nURL: %s",
req.Issue.Fields.RequestType.Name, req.Issue.Fields.Summary, req.User.Name,
req.Issue.Fields.CustomField11401.Links.Web)
}
4 changes: 4 additions & 0 deletions internal/webhook-proxy/request/request.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ type Jira struct {
Web string `json:"web"`
} `json:"_links"`
} `json:"customfield_11401"`
RequestType struct {
Name string `json:"name"`
Description string `json:"description"`
} `json:"requestType"`
Summary string `json:"summary"`
IssueType struct {
Description string `json:"description"`
Expand Down

0 comments on commit 8c1a02e

Please sign in to comment.