You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
500 B

const _ = require('lodash');
const Debug = require('../../helper/debug');
const debugLog = new Debug('controller:predicates:is_addressit_parse');
const stackTraceLine = require('../../helper/stackTraceLine');
8 years ago
// returns true IFF req.clean.parser is addressit
module.exports = (req, res) => {
const is_addressit_parse = _.get(req, 'clean.parser') === 'addressit';
debugLog.push(req, () => ({
reply: is_addressit_parse,
stack_trace: stackTraceLine()
}));
return is_addressit_parse;
};