Browse Source

Moved includes check from lodash to native array in is_request_sources_includes_whosonfirst

pull/1165/head
Tyler Pedelose 7 years ago committed by Julian Simioni
parent
commit
be82c05c92
No known key found for this signature in database
GPG Key ID: B9EEB0C6EE0910A1
  1. 3
      controller/predicates/is_request_sources_includes_whosonfirst.js

3
controller/predicates/is_request_sources_includes_whosonfirst.js

@ -5,8 +5,7 @@ const stackTraceLine = require('../../helper/stackTraceLine');
// returns true IFF 'whosonfirst' is included in the requested sources // returns true IFF 'whosonfirst' is included in the requested sources
module.exports = (req, res) => { module.exports = (req, res) => {
const is_request_sources_includes_whosonfirst = _.includes( const is_request_sources_includes_whosonfirst = _.get(req, 'clean.sources', []).includes(
_.get(req, 'clean.sources', []),
'whosonfirst' 'whosonfirst'
); );
debugLog.push(req, () => ({ debugLog.push(req, () => ({

Loading…
Cancel
Save