From ace32ed711c141c555a5bf35addb5f5710e197ae Mon Sep 17 00:00:00 2001 From: Gubolin Date: Sat, 13 Sep 2014 12:58:15 +0200 Subject: don't do nothing if the GitHub user has no repos --- github.js | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'github.js') diff --git a/github.js b/github.js index f231e6d..66a4547 100644 --- a/github.js +++ b/github.js @@ -259,6 +259,10 @@ GitHubBackend.prototype.getProjectList = function (callBack, errorCall) { }; })(); + if (repos.length === 0) { + callBack.call(myself, snapProjects); + } + repos.forEach(function (repo) { if (repo.description.indexOf('Snap! Project') > -1) { // TODO nicer detection var project, ghrepo, branch; -- cgit v1.3.1