Promise .all([ queryCollaborators({ repositoryOwner, repositoryName }), queryCommits({ repositoryOwner, repositoryName, since }) ]) .then(results => { const collaborators = _.keyBy(results[0], 'login') return _.chain(results[1]) .map('author.user') .reject(_.isEmpty) .groupBy('login') .map(group => _.defaults({ commits: _.size(group) }, _.head(group))) .filter(user => _.isEmpty(collaborators[user.login])) .value() }) .then(res => formatOutput(res)) .catch(err => console.log(err))
return queryCollaborators(_.defaults({ collaboratorsAfter }, variables)) .then(others => _.concat(collaborators, others)) })
return queryCommits(_.defaults({ historyAfter }, variables)) .then(others => _.concat(commits, others)) })
constructor (props) { _.defaults(this, props) this.busAckTimeout = this.server.busAckTimeout this.clusterBus = this.server.clusterBus this.onJoin = this.server.hooks.onJoin this.onLeave = this.server.hooks.onLeave this.lockTTL = this.state.lockTTL mixin(this, UserReports, this.transport, this.echoChannel) }
constructor(snowmix, id, args, defaults) { this.snowmix = snowmix if (id) this.id = parseInt(id) if (args) Object.assign(this, args) if (defaults) _.defaults(this, defaults) }
Promise.method(function startRekey(options) { options = _.defaults(options || {}, { secret_shares: this.config.get('secret_shares'), secret_threshold: this.config.get('secret_threshold') }); return this.getRekeyInitEndpoint() .put({ headers: this.headers, body: options, _token: options.token }); })
constructor (name, schema) { if (!name || !_.isString(name)) { throw new TypeError('Schema must have a name') } super(name, _.defaults(schema, { _id: { type: Types.ObjectId } })) }
constructor(bindName, container, target, dependencies, options) { this.bindName = bindName; this.container = container; this.target = target; this.dependencies = dependencies; this.options = _.defaults(options, { initialize: false }); }
constructor(snowmix, id, args) { super(snowmix) const defaults = { id: parseInt(id), name: 'AudioFeed #' + id, channels: 2, rate: 44100, signess: 'signed' } _.defaults(this, args, defaults) }
Promise .all([ queryCollaborators({ repositoryOwner, repositoryName }), queryCommits({ repositoryOwner, repositoryName, since }) ]) .then(results => { const collaborators = _.keyBy(results[0], 'login') return _.chain(results[1]) .map('author.user') .reject(_.isEmpty) .groupBy('login') .map(group => _.defaults({ commits: _.size(group) }, _.head(group))) .filter(user => _.isEmpty(collaborators[user.login])) .value() }) .then(res => formatOutput(res)) .catch(err => console.log(err))
return queryCollaborators(_.defaults({ collaboratorsAfter }, variables)) .then(others => _.concat(collaborators, others)) })
return queryCommits(_.defaults({ historyAfter }, variables)) .then(others => _.concat(commits, others)) })
constructor(snowmix, id, args) { super(snowmix) const defaults = { id: parseInt(id), name: 'AudioSink #' + id, channels: 2, rate: 44100, signess: 'signed' } _.defaults(this, args, defaults) }