summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorprzemyslawpluta <przemekpluta@hotmail.com>2014-02-17 19:09:02 +0000
committerprzemyslawpluta <przemekpluta@hotmail.com>2014-02-17 19:09:02 +0000
commitda6cd89321af91524f51dd2ea9b959738505cba4 (patch)
tree18e4d022a3eb9377d445818c1db00360222b499a
parentc9c95c52d4265f0bd8925946f43668a2d07cc41d (diff)
downloadmongo-edu-da6cd89321af91524f51dd2ea9b959738505cba4.zip
cater for other courses
-rw-r--r--lib/login.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/login.js b/lib/login.js
index c28c334..694b2a5 100644
--- a/lib/login.js
+++ b/lib/login.js
@@ -113,7 +113,7 @@ module.exports = {
if (current.text().indexOf('Video') !== -1) { list.push(current.attr('href')); }
});
- getCourses = _.filter(list, function map(item) { return (item.indexOf('wiki/M101') !== -1); });
+ getCourses = _.filter(list, function map(item) { return item.match(/(wiki\/M101|wiki\/M102|wiki\/C100|wiki\/M202)/); });
callback(null, _.map(getCourses, function map(item) { return { name: item.replace(tag, '').slice(0, -1).slice(1).replace(/-/g, ' ').replace(/\//g, ': '), value: item }; }));
}