Merge branch 'staging' of github.com:FreeCodeCamp/freecodecamp into staging
This commit is contained in:
@ -60,7 +60,7 @@
|
||||
"lodash": "^3.9.3",
|
||||
"loopback": "https://github.com/FreeCodeCamp/loopback.git#fix/no-password",
|
||||
"loopback-boot": "^2.8.0",
|
||||
"loopback-component-passport": "git://github.com/FreeCodeCamp/loopback-component-passport.git#feature/emailOptional",
|
||||
"loopback-component-passport": "1.4.0",
|
||||
"loopback-connector-mongodb": "^1.10.0",
|
||||
"lusca": "~1.0.2",
|
||||
"method-override": "~2.3.0",
|
||||
|
@ -7,6 +7,7 @@ var Rx = require('rx'),
|
||||
secrets = require('../config/secrets');
|
||||
|
||||
var MongoClient = mongodb.MongoClient;
|
||||
Rx.config.longStackSupport = true;
|
||||
|
||||
var providers = [
|
||||
'facebook',
|
||||
@ -164,6 +165,7 @@ var commentCount = dbObservable
|
||||
.flatMap(function(db) {
|
||||
return createQuery(db, 'comments', {});
|
||||
})
|
||||
.bufferWithCount(20)
|
||||
.withLatestFrom(dbObservable, function(comments, db) {
|
||||
return {
|
||||
comments: comments,
|
||||
@ -173,7 +175,6 @@ var commentCount = dbObservable
|
||||
.flatMap(function(dats) {
|
||||
return insertMany(dats.db, 'comment', dats.comments, { w: 1 });
|
||||
})
|
||||
.buffer(20)
|
||||
.count();
|
||||
|
||||
Rx.Observable.combineLatest(
|
||||
@ -198,7 +199,6 @@ Rx.Observable.combineLatest(
|
||||
console.error('an error occured', err, err.stack);
|
||||
},
|
||||
function() {
|
||||
|
||||
console.log('finished with ', count);
|
||||
process.exit(0);
|
||||
}
|
||||
|
Reference in New Issue
Block a user