diff --git a/build-scripts/gulp/download_translations.js b/build-scripts/gulp/download_translations.js index e25ac8ca97..788d4ff896 100644 --- a/build-scripts/gulp/download_translations.js +++ b/build-scripts/gulp/download_translations.js @@ -16,7 +16,7 @@ function hasHtml(data) { return /<[a-z][\s\S]*>/i.test(data); } -function hasUnquotedHTags(data) { +function hasUnquotedTags(data) { // Guard against unquoted HTML tags https://github.com/formatjs/formatjs/issues/1878 return /[^'](<.*>)[^']/i.test(data); } @@ -28,7 +28,7 @@ function recursiveCheckHasHtml(file, data, errors, recKey) { recursiveCheckHasHtml(file, data[key], errors, nextRecKey); } else if (hasHtml(data[key])) { errors.push(`HTML found in ${file.path} at key ${recKey}.${key}`); - } else if (hasUnquotedHTags(data[key])) { + } else if (hasUnquotedTags(data[key])) { errors.push( `Unquoted tags found in ${file.path} at key ${recKey}.${key}` );