v1.18.x
Barış Soner Uşaklı 8 years ago
parent 3ae3d788be
commit 5a9b7b673a

@ -15,7 +15,7 @@ var utils = require('../public/src/utils');
var _ = require('underscore'); var _ = require('underscore');
var S = require('string'); var S = require('string');
var Flags = {}; var Flags = module.exports;
Flags.get = function (flagId, callback) { Flags.get = function (flagId, callback) {
async.waterfall([ async.waterfall([
@ -26,6 +26,9 @@ Flags.get = function (flagId, callback) {
notes: async.apply(Flags.getNotes, flagId), notes: async.apply(Flags.getNotes, flagId),
}), }),
function (data, next) { function (data, next) {
if (!data.base) {
return callback();
}
// Second stage // Second stage
async.parallel({ async.parallel({
userObj: async.apply(user.getUserFields, data.base.uid, ['username', 'userslug', 'picture']), userObj: async.apply(user.getUserFields, data.base.uid, ['username', 'userslug', 'picture']),

Loading…
Cancel
Save