guard against know_generated when using minify_info in native optimizer

This commit is contained in:
Alon Zakai 2015-06-26 12:06:28 -07:00
Родитель 4fdee3a14f
Коммит 228e090539
1 изменённых файлов: 7 добавлений и 6 удалений

Просмотреть файл

@ -399,12 +399,13 @@ EMSCRIPTEN_FUNCS();
f.write(chunk)
f.write(suffix_marker)
if minify_globals:
if extra_info:
for key, value in extra_info.iteritems():
assert key not in minify_info or value == minify_info[key], [key, value, minify_info[key]]
minify_info[key] = value
f.write('\n')
f.write('// EXTRA_INFO:' + json.dumps(minify_info))
if know_generated:
if extra_info:
for key, value in extra_info.iteritems():
assert key not in minify_info or value == minify_info[key], [key, value, minify_info[key]]
minify_info[key] = value
f.write('\n')
f.write('// EXTRA_INFO:' + json.dumps(minify_info))
elif extra_info:
f.write('\n')
f.write('// EXTRA_INFO:' + json.dumps(extra_info))