lib/filters/filter.js
function isFilter(filter) {
  if (!filter || typeof (filter) !== 'object') {
    return false;
  }
  // Do our best to duck-type it
  if (typeof (filter.toBer) === 'function' &&
      typeof (filter.matches) === 'function' &&
      TYPES[filter.type] !== undefined) {
    return true;
  }
  return false;
}
function isFilter(filter) {
  if (!filter || typeof (filter) !== 'object') {
    return false;
  }
  // Do our best to duck-type it
  if (typeof (filter.toBer) === 'function' &&
      typeof (filter.matches) === 'function' &&
      TYPES[filter.type] !== undefined) {
    return true;
  }
  return false;
}
/--- API