Skip to content

Commit

Permalink
build: fix mapping of ".pullRequests.createFromissue()" endpoint method
Browse files Browse the repository at this point in the history
  • Loading branch information
gr2m committed Oct 6, 2018
1 parent ddc50c0 commit 85b0343
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/generate-routes.js
Expand Up @@ -52,7 +52,7 @@ function matchesRoute (currentEndpoint, newEndpoint) {
// a. repos.updateFile
const route = `${newEndpoint.method} ${newEndpoint.path}`
const additionalParameter = {
'POST /repos/:owner/:repo/pulls': 'issues',
'POST /repos/:owner/:repo/pulls': 'issue',
'POST /repos/:owner/:repo/pulls/:number/comments': 'in_reply_to',
'PUT /repos/:owner/:repo/contents/:path': 'sha'
}[route]
Expand Down Expand Up @@ -170,7 +170,7 @@ Object.keys(CURRENT_ROUTES).sort().forEach(scope => {
}

if (currentEndpoint.deprecated) {
console.log(`No endpoint found for deprecated ${currentEndpoint.method} ${currentEndpoint.url}, leaving route as is.`)
console.log(`No endpoint found for deprecated method ${scope}.${methodName}, leaving route as is.`)
newRoutes[scope][methodName] = currentEndpoint
return
}
Expand Down

0 comments on commit 85b0343

Please sign in to comment.