Created
July 22, 2012 22:42
-
-
Save billyvg/3161268 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
list: (socket, msg, fn) -> | |
results = [] | |
expectedCount = 0 | |
addResult = (result) -> | |
results.push result | |
fn results if results.length is expectedCount | |
r.lrange 'boards', 0, -1, (err, items) -> | |
expectedCount = items.length | |
_.each items, (item) -> | |
r.hgetall "board:#{ item }", (err, details) -> | |
addResult details |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment