[courier/segmentedRequest] mark the request "started" synchronously

This commit is contained in:
spalger 2016-03-24 14:35:00 -07:00
parent fd2f9d87ce
commit 8a4992640b

View file

@ -42,6 +42,8 @@ export default function SegmentedReqProvider(es, Private, Promise, timefilter, c
*********/ *********/
start() { start() {
super.start();
this._complete = []; this._complete = [];
this._active = null; this._active = null;
this._segments = []; this._segments = [];
@ -61,12 +63,12 @@ export default function SegmentedReqProvider(es, Private, Promise, timefilter, c
// parameters via the handle // parameters via the handle
if (_.isFunction(this._initFn)) this._initFn(this._handle); if (_.isFunction(this._initFn)) this._initFn(this._handle);
return this._createQueue().then((queue) => { return this._createQueue().then((queue) => {
if (this.stopped) return;
this._all = queue.slice(0); this._all = queue.slice(0);
// Send the initial fetch status // Send the initial fetch status
this._reportStatus(); this._reportStatus();
return super.start();
}); });
} }