summaryrefslogtreecommitdiff
path: root/users/app/designs/user/by_email_alias.js
blob: 51eb976f2939e74699186745dff4f492c719435d (plain)
1
2
3
4
5
6
7
8
function(doc) {
  if (doc.type != 'User') {
    return;
  }
  doc.email_aliases.forEach(function(alias){
    emit(alias.email, doc);
  });
}