(item *models.Item)
| 388 | } |
| 389 | |
| 390 | func extractPRFromItem(item *models.Item) *GitHubPR { |
| 391 | if item == nil || item.CodeContext == nil || item.CodeContext.PullRequest == nil { |
| 392 | return nil |
| 393 | } |
| 394 | pr := item.CodeContext.PullRequest |
| 395 | return &GitHubPR{ |
| 396 | Number: pr.Number, |
| 397 | URL: pr.URL, |
| 398 | Title: pr.Title, |
| 399 | State: pr.State, |
| 400 | Branch: item.CodeContext.Branch, |
| 401 | Repo: item.CodeContext.Repo, |
| 402 | UpdatedAt: pr.UpdatedAt, |
| 403 | } |
| 404 | } |
| 405 | |
| 406 | func prStateColor(state string) *color.Color { |
| 407 | switch state { |
no outgoing calls
no test coverage detected