diff --git a/src/middleware/requestMatching.js b/src/middleware/requestMatching.js index 3808a7db..57738ba7 100644 --- a/src/middleware/requestMatching.js +++ b/src/middleware/requestMatching.js @@ -26,7 +26,7 @@ function matchContent (channel, ctx) { } function matchMethod(channel, ctx) { - return channel.methods.find(method => ctx.request.method.toUpperCase() === method) ? true : false + return !!channel.methods.find(method => ctx.request.method.toUpperCase() === method) } function matchRegex (regexPat, body) {