src/log.js
function addFilter (config, filter) {
  if (filter) {
    if (filter[ 0 ] === '-') {
      config.filters.ignore[ filter ] = new RegExp('^' + filter.slice(1).replace(/[*]/g, '.*?') + '$')
    } else {
      config.filters.should[ filter ] = new RegExp('^' + filter.replace(/[*]/g, '.*?') + '$')
    }
  }
}
function addFilter (config, filter) {
  if (filter) {
    if (filter[ 0 ] === '-') {
      config.filters.ignore[ filter ] = new RegExp('^' + filter.slice(1).replace(/[*]/g, '.*?') + '$')
    } else {
      config.filters.should[ filter ] = new RegExp('^' + filter.replace(/[*]/g, '.*?') + '$')
    }
  }
}
function addFilter ( config , filter ) { if ( filter ) { if ( filter [ 0 ] === '-' ) { config . filters . ignore [ filter ] = new RegExp ( '^' + filter . slice ( 1 ) . replace ( / [*] / g , '.*?' ) + '$' ) } else { config . filters . should [ filter ] = new RegExp ( '^' + filter . replace ( / [*] / g , '.*?' ) + '$' ) } } }
add the regex filter to the right hash for use later
add the regex filter to the right hash for use later