lib/js/searchOps.js
function filterTabWindows(tabWindows, searchExp) {
  var res;
  if (searchExp === null) {
    res = _.map(tabWindows, function (tw) {
      return new FilteredTabWindow({ tabWindow: tw });
    });
  } else {
    var mappedWindows = _.map(tabWindows, function (tw) {
      return matchTabWindow(tw, searchExp);
    });
    res = _.filter(mappedWindows, function (fw) {
      return fw !== null;
    });
  }

  return res;
}
function filterTabWindows(tabWindows, searchExp) {
  var res;
  if (searchExp === null) {
    res = _.map(tabWindows, function (tw) {
      return new FilteredTabWindow({ tabWindow: tw });
    });
  } else {
    var mappedWindows = _.map(tabWindows, function (tw) {
      return matchTabWindow(tw, searchExp);
    });
    res = _.filter(mappedWindows, function (fw) {
      return fw !== null;
    });
  }

  return res;
}
function filterTabWindows ( tabWindows , searchExp ) { var res ; if ( searchExp === null ) { res = _ . map ( tabWindows , function ( tw ) { return new FilteredTabWindow ( { tabWindow : tw } ) ; } ) ; } else { var mappedWindows = _ . map ( tabWindows , function ( tw ) { return matchTabWindow ( tw , searchExp ) ; } ) ; res = _ . filter ( mappedWindows , function ( fw ) { return fw !== null ; } ) ; } return res ; }
filter an array of TabWindows using a searchRE to obtain
an array of FilteredTabWindow
filter an array of TabWindows using a searchRE to obtain an array of FilteredTabWindow