From 9a3dd5cfd3f7a897ea0bcfce02f568b653c63356 Mon Sep 17 00:00:00 2001 From: Stuart Taylor Date: Thu, 28 Jun 2018 23:02:48 +0100 Subject: [PATCH] fix(blacklist): Sure up blacklisted usernames --- server/utils/constants.js | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/server/utils/constants.js b/server/utils/constants.js index 4b3c8d6676..f9c75c636b 100644 --- a/server/utils/constants.js +++ b/server/utils/constants.js @@ -1,13 +1,25 @@ +let alphabet = ''; + +for (let i = 0; i < 26; i++) { + alphabet = alphabet.concat(String.fromCharCode(97 + i)); +} + export const blacklistedUsernames = [ + ...alphabet.split(''), 'about', + 'academic-honesty', 'account', 'agile', + 'all-stories', 'api', + 'backend-challenge-completed', 'bonfire', 'cats.json', 'challenge', + 'challenge-completed', 'challenges', 'chat', + 'coding-bootcamp-cost-calculator', 'completed-bonfire', 'completed-challenge', 'completed-field-guide', @@ -23,6 +35,7 @@ export const blacklistedUsernames = [ 'get-help', 'get-pai', 'guide', + 'how-nonprofit-projects-work', 'internal', 'jobs', 'jobs-form', @@ -30,23 +43,33 @@ export const blacklistedUsernames = [ 'login', 'logout', 'map', + 'modern-challenge-completed', 'news', 'nonprofits', - 'nonprofits', 'nonproifts-form', 'open-api', + 'pmi-acp-agile-project-managers', + 'pmi-acp-agile-project-managers-form', 'privacy', 'privacy', + 'project-completed', 'reset', 'services', 'signin', 'signout', 'sitemap.xml', + 'software-resources-for-nonprofits', 'stories', 'terms', + 'the-fastest-web-page-on-the-internet', 'twitch', 'unsubscribe', 'unsubscribed', + 'update-my-portfolio', + 'update-my-profile-ui', + 'update-my-projects', + 'update-my-theme', + 'update-my-username', 'user', 'wiki' ];