diff --git a/config.js.example b/config.js.example index 178ee8be..b82b591b 100644 --- a/config.js.example +++ b/config.js.example @@ -28,3 +28,4 @@ global.LDAP_URL = "ldaps://localhost:636"; global.LDAP_SEARCH_BASE = 'ou=user,dc=example,dc=org'; // LDAP_BIND_DN must contain the placeholder {{username}} global.LDAP_BIND_DN = 'uid={{username}},ou=user,dc=example,dc=org'; +global.GH_TOKEN = '123foobar'; diff --git a/lib/transition-checker.js b/lib/transition-checker.js index 83a75e5f..5aad580a 100644 --- a/lib/transition-checker.js +++ b/lib/transition-checker.js @@ -24,18 +24,19 @@ TransitionChecker.check = function (profile, latestVersion, previousVersion) { if (previousVersion.includes("/WD-") || !editorial) { var shortname = latestVersion.match(new RegExp(/.*\/([^/]+)\/$/))[1]; var octo = new Octokat({ - token: "" // TODO: create token + token: global.GH_TOKEN; }); var shortname = 'css-text-decor-3'; var repo = octo.repos('w3c', 'transitions'); var approvalText = "Please update the Re"; - repo.issues.fetch({ - labels: 'Awaiting publication', - state: 'open', - per_page: 100 - }) + repo.issues.fetch( + { + labels: 'Awaiting publication', + state: 'open', + per_page: 100 + }) .then((content) => { for (var issue of content.items) { if (issue.title.endsWith(' ' + shortname)) {