From 6ce8738fc013bb830bd467d223f7bea8fab42c3f Mon Sep 17 00:00:00 2001 From: Oliver Eyton-Williams Date: Fri, 10 Dec 2021 23:35:46 +0100 Subject: [PATCH] refactor: remove useless warning (#44465) --- client/package.json | 2 +- tools/challenge-parser/translation-parser/index.js | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/client/package.json b/client/package.json index df926acc3ab..505718776c3 100644 --- a/client/package.json +++ b/client/package.json @@ -24,7 +24,7 @@ "build:workers": "cross-env NODE_OPTIONS=\"--max-old-space-size=7168\" webpack --config ./webpack-workers.js", "clean": "gatsby clean", "predevelop": "tsc -p ../tools/ && node ../tools/scripts/build/ensure-env.js && npm run build:workers -- --env development", - "develop": "cross-env NODE_OPTIONS=\"--max-old-space-size=4000\" gatsby develop --inspect=9230", + "develop": "cross-env NODE_OPTIONS=\"--max-old-space-size=5000\" gatsby develop --inspect=9230", "lint": "node ./i18n/schema-validation.js", "serve": "gatsby serve -p 8000", "serve-ci": "serve -l 8000 -c ../serve.json public", diff --git a/tools/challenge-parser/translation-parser/index.js b/tools/challenge-parser/translation-parser/index.js index 4283cfd2055..841272650dc 100644 --- a/tools/challenge-parser/translation-parser/index.js +++ b/tools/challenge-parser/translation-parser/index.js @@ -17,9 +17,7 @@ exports.translateComments = (text, lang, dict, codeLang) => { exports.translateCommentsInChallenge = (challenge, lang, dict) => { const challClone = cloneDeep(challenge); - if (!challClone.challengeFiles) { - console.warn(`Challenge ${challClone.title} has no seed to translate`); - } else { + if (challClone?.challengeFiles) { challClone.challengeFiles.forEach(challengeFile => { if (challengeFile.contents) { let { text, commentCounts } = this.translateComments(