Skip to content

Commit

Permalink
Fix GithubIssueDetail
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmelnikow committed Jan 12, 2019
1 parent 24c1178 commit 628618f
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions services/github/github-issue-detail.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,7 @@ module.exports = class GithubIssueDetail extends LegacyService {
case 's': {
const state = (badgeData.text[1] = parsedData.state)
badgeData.colorscheme = undefined
badgeData.colorB = makeColorB(
githubStateColor(state),
queryParams
)
badgeData.colorB = queryParams.colorB || githubStateColor(state)
break
}
case 'title':
Expand All @@ -137,20 +134,16 @@ module.exports = class GithubIssueDetail extends LegacyService {
.join(' | ')
if (parsedData.labels.length === 1) {
badgeData.colorscheme = undefined
badgeData.colorB = makeColorB(
parsedData.labels[0].color,
queryParams
)
badgeData.colorB =
queryParams.colorB || parsedData.labels[0].color
}
break
case 'comments': {
badgeData.text[0] = getLabel('comments', queryParams)
const comments = (badgeData.text[1] = parsedData.comments)
badgeData.colorscheme = undefined
badgeData.colorB = makeColorB(
githubCommentsColor(comments),
queryParams
)
badgeData.colorB =
queryParams.coloB || githubCommentsColor(comments)
break
}
case 'age':
Expand Down

0 comments on commit 628618f

Please sign in to comment.