lib/transform/standardize.js
function onlyOneFieldAttribute(fieldsList, keyword) {
  if (fieldsList.length > 1) {
    return Bluebird.reject(new BadRequestError(`"${keyword}" can contain only one attribute`));
  }

  return Bluebird.resolve(fieldsList);
}
function onlyOneFieldAttribute(fieldsList, keyword) {
  if (fieldsList.length > 1) {
    return Bluebird.reject(new BadRequestError(`"${keyword}" can contain only one attribute`));
  }

  return Bluebird.resolve(fieldsList);
}
function onlyOneFieldAttribute ( fieldsList , keyword ) { if ( fieldsList . length > 1 ) { return Bluebird . reject ( new BadRequestError ( ` ${ keyword } ` ) ) ; } return Bluebird . resolve ( fieldsList ) ; }
Verifies that "filter" contains only 1 field
@param {Array} fieldsList
@param {string} keyword
@returns {Promise} Promise resolving to the provided fields list
Verifies that filter contains only 1 field