fix buffer return from database query
This commit is contained in:
@ -165,6 +165,7 @@ var commentCount = dbObservable
|
|||||||
.flatMap(function(db) {
|
.flatMap(function(db) {
|
||||||
return createQuery(db, 'comments', {});
|
return createQuery(db, 'comments', {});
|
||||||
})
|
})
|
||||||
|
.bufferWithCount(20)
|
||||||
.withLatestFrom(dbObservable, function(comments, db) {
|
.withLatestFrom(dbObservable, function(comments, db) {
|
||||||
return {
|
return {
|
||||||
comments: comments,
|
comments: comments,
|
||||||
@ -174,7 +175,6 @@ var commentCount = dbObservable
|
|||||||
.flatMap(function(dats) {
|
.flatMap(function(dats) {
|
||||||
return insertMany(dats.db, 'comment', dats.comments, { w: 1 });
|
return insertMany(dats.db, 'comment', dats.comments, { w: 1 });
|
||||||
})
|
})
|
||||||
.bufferWithCount(20)
|
|
||||||
.count();
|
.count();
|
||||||
|
|
||||||
Rx.Observable.combineLatest(
|
Rx.Observable.combineLatest(
|
||||||
|
Reference in New Issue
Block a user