Skip to content

Commit 66c0c47

Browse files
committed
Fix lint error. Fix script bug
1 parent eeade9c commit 66c0c47

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

lib/models/apis/github.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -487,7 +487,8 @@ Github.prototype.addComment = function(shortRepo, issueId, text, cb) {
487487
debug('back from creating issue comment', err);
488488
if (err) {
489489
err = (err.code === 404) ?
490-
Boom.notFound('Issue ' + shortRepo + '/issues/' + issueId + ' not found.', { err: err, report: false }) :
490+
Boom.notFound('Issue ' + shortRepo + '/issues/' + issueId + ' not found.',
491+
{ err: err, report: false }) :
491492
Boom.create(502, 'Failed to get issue comments ' + shortRepo + '/issues/' + issueId ,
492493
{ err: err });
493494
cb(err);

scripts/update-github-webhooks-event.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,15 @@ function findUser (users, cb) {
2424
var user;
2525
var count = 0;
2626
async.whilst(
27-
function () { return !user || count < users.length; },
27+
function () { return count < users.length; },
2828
function (callback) {
2929
var u = users[count];
30-
count++;
3130
User.findByGithubId(user, function (err, gitHubUser) {
31+
count++;
3232
if (gitHubUser) {
33+
// force finish
3334
user = gitHubUser;
35+
count = users.length;
3436
}
3537
callback();
3638
});

0 commit comments

Comments
 (0)