1
0
mirror of https://github.com/badges/shields.git synced 2025-10-22 20:32:32 +03:00

Unify remaining service order and enforce (#3359)

Ref #3353
This commit is contained in:
Paul Melnikow
2019-04-24 16:53:33 -04:00
committed by GitHub
parent f8aeb56129
commit 0088a9d0da
38 changed files with 665 additions and 665 deletions

View File

@@ -88,6 +88,10 @@ const whichMap = {
}
module.exports = class CodeclimateAnalysis extends BaseJsonService {
static get category() {
return 'analysis'
}
static get route() {
return {
base: 'codeclimate',
@@ -96,10 +100,6 @@ module.exports = class CodeclimateAnalysis extends BaseJsonService {
}
}
static get category() {
return 'analysis'
}
static get examples() {
return [
{
@@ -140,6 +140,12 @@ module.exports = class CodeclimateAnalysis extends BaseJsonService {
]
}
static render({ which, ...props }) {
const { render } = whichMap[which]
return render(props)
}
async fetch({ user, repo }) {
const {
id: repoId,
@@ -159,12 +165,6 @@ module.exports = class CodeclimateAnalysis extends BaseJsonService {
return data
}
static render({ which, ...props }) {
const { render } = whichMap[which]
return render(props)
}
async handle({ which, user, repo }) {
const { transform } = whichMap[which]