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