mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Fix "Cursor is closed" intermittent error.
If the initial _doPoll didn't complete before the first markDirty, two doPolls could be running at once, causing badness.
This commit is contained in:
@@ -436,7 +436,9 @@ _Mongo.LiveResultsSet = function (cursor, options) {
|
||||
self.removed = options.removed;
|
||||
|
||||
// run the first _poll() cycle synchronously.
|
||||
self.poll_running = true;
|
||||
self._doPoll();
|
||||
self.poll_running = false;
|
||||
|
||||
// every once and a while, poll even if we don't think we're dirty,
|
||||
// for eventual consistency with database writes from outside the
|
||||
|
||||
Reference in New Issue
Block a user