Remove "const" in uncompiled code (#10631)

Test Plan: All fixtures/packaging iframes display correctly on Chrome 38.0.2125.0 from https://commondatastorage.googleapis.com/chromium-browser-snapshots/index.html?prefix=Mac/290001/; previously several were blank with "Use of const in strict mode" errors logged to the console.
This commit is contained in:
Sophie Alpert
2017-09-06 20:32:15 -07:00
committed by GitHub
parent d8ecc4c2b5
commit 16a39b8f02
+2 -2
View File
@@ -8,8 +8,8 @@ function testMinificationUsedDCE() {
try {
// use scoped variable for our initial test, in case
// 'top-level' mangling is not enabled.
const source = testMinificationUsedDCE.toString();
const longVariableName = true;
var source = testMinificationUsedDCE.toString();
var longVariableName = true;
if (longVariableName && source.match(/longVariableName/g).length === 3) {
// We are not minified.
// This might be a Node environment where DCE is not expected anyway.