web/lib/results.js
function normalizeResult(result) {
  if (result.uri) {
    console.log('normalizing', result);
    if (!result._source) {
      result._source = {};
    }
    ['title', 'timestamp', 'uri', 'annotationSummary', 'annotations', 'visitors'].forEach(function(f) {
      result._source[f] = result[f];
    });
  }
  return result;
}
function normalizeResult(result) {
  if (result.uri) {
    console.log('normalizing', result);
    if (!result._source) {
      result._source = {};
    }
    ['title', 'timestamp', 'uri', 'annotationSummary', 'annotations', 'visitors'].forEach(function(f) {
      result._source[f] = result[f];
    });
  }
  return result;
}
function normalizeResult ( result ) { if ( result . uri ) { console . log ( 'normalizing' , result ) ; if ( ! result . _source ) { result . _source = { } ; } [ 'title' , 'timestamp' , 'uri' , 'annotationSummary' , 'annotations' , 'visitors' ] . forEach ( function ( f ) { result . _source [ f ] = result [ f ] ; } ) ; } return result ; }
FIXME normalize fields between base and _source
FIXME normalize fields between base and _source