Permalink
Browse files

rsm_queue: robustify callback() shortcut on end_reached

fixes a fatal bug
  • Loading branch information...
1 parent 950e01b commit 5d123927868711fdcada516364acd48ef434e35c @astro astro committed Feb 28, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/handlers/rsm_queue.coffee
@@ -15,8 +15,8 @@ class exports.RSMQueue
# Reset RSM:
delete node["#{@name}_rsm"]
- if rsm_info and rsm_info.end_reached
- cb(null, [])
+ if rsm_info?.end_reached
+ cb? null, [], yes
else
@queued[id] = [cb]

0 comments on commit 5d12392

Please sign in to comment.