fix json validation

This commit is contained in:
Brian Seymour 2021-05-07 14:42:55 -05:00
parent 5830d7fb43
commit 3ea6ca1180
1 changed files with 1 additions and 1 deletions

View File

@ -8,7 +8,7 @@ const package = require('../package')
const logger = require('logplease').create('api/v2');
router.use((req, res, next) => {
if (!req.body || req.body === '') {
if (['GET', 'HEAD', 'OPTIONS'].includes(req.method) || !req.body) {
return next();
}