diff options
author | jessib <jessib@riseup.net> | 2013-04-09 10:05:41 -0700 |
---|---|---|
committer | jessib <jessib@riseup.net> | 2013-04-09 10:05:41 -0700 |
commit | 25ef7a4c41cfca4c3d481236d8c75a0d4c54f3b9 (patch) | |
tree | 5fd426c9719e2f687fc6145468af5d54cea2ab17 /users/app/designs | |
parent | 1ca17ae19a6997e12b180b49637d18850d04a774 (diff) | |
parent | 6779013445c3fabfe2a7879ffe8c155f10a255c9 (diff) |
Merge pull request #43 from azul/feature/pgp_key_by_email_view
adding view of pgp key by login or email aliases
Diffstat (limited to 'users/app/designs')
-rw-r--r-- | users/app/designs/user/email_by_login_or_alias.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/users/app/designs/user/email_by_login_or_alias.js b/users/app/designs/user/email_by_login_or_alias.js new file mode 100644 index 0000000..2a86d68 --- /dev/null +++ b/users/app/designs/user/email_by_login_or_alias.js @@ -0,0 +1,9 @@ +function(doc) { + if (doc.type != 'User') { + return; + } + emit(doc.login, doc.public_key); + doc.email_aliases.forEach(function(alias){ + emit(alias.username, doc.public_key); + }); +} |