Created
December 30, 2015 07:52
-
-
Save lokedhs/826bbf479af38f1b5c9e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function (doc) { | |
return doc.type === 'user_notification' && !doc.read && doc.ping_timestamp != null ? emit(doc.ping_timestamp, [doc.user]) : null; | |
}); | |
(function (key, values, rereduce) { | |
var result = { }; | |
for (var value = null, _js_idx1 = 0; _js_idx1 < values.length; _js_idx1 += 1) { | |
value = values[_js_idx1]; | |
for (var uid = null, _js_idx2 = 0; _js_idx2 < value.length; _js_idx2 += 1) { | |
uid = value[_js_idx2]; | |
result[uid] = null; | |
}; | |
}; | |
return Object.keys(result); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment