Created
February 4, 2012 02:49
-
-
Save dyoder/1734704 to your computer and use it in GitHub Desktop.
Scenario
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
subscribe: () -> | |
context = @context | |
spire = @context.spire | |
iteration = @context.iteration | |
spire.messages.subscribe "channel #{iteration}", {maxCallCount: 1}, | |
(error,messages) -> | |
if error | |
context.error(error) | |
return | |
context.finish() | |
# TODO: verify content of messages | |
for message in messages | |
console.log message |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment