Skip to content

Commit

Permalink
fix: throw 400 Bad Request error when octokit.issues.get() without …
Browse files Browse the repository at this point in the history
…parameters
  • Loading branch information
gr2m committed Apr 17, 2019
1 parent e0824a8 commit a102378
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions plugins/register-endpoints/register-endpoints.js
Expand Up @@ -62,6 +62,10 @@ function registerEndpoints (octokit, routes) {

function patchForDeprecation (octokit, apiOptions, method, methodName) {
const patchedMethod = (options) => {
if (!options) {
return method(options)
}

Object.keys(options).forEach(key => {
if (apiOptions.params[key] && apiOptions.params[key].deprecated) {
const aliasKey = apiOptions.params[key].alias
Expand Down

0 comments on commit a102378

Please sign in to comment.