Unverified Commit e3ea413a authored by Adam Cozzette's avatar Adam Cozzette Committed by GitHub

Merge pull request #4780 from mwei0210/master

check provided size to check whether to export
parents 761a6275 6074aaa9
......@@ -3477,7 +3477,8 @@ void Generator::GenerateFile(const GeneratorOptions& options,
GenerateExtension(options, printer, *it);
}
if (options.import_style == GeneratorOptions::kImportCommonJs) {
// if provided is empty, do not export anything
if (options.import_style == GeneratorOptions::kImportCommonJs && !provided.empty()) {
printer->Print("goog.object.extend(exports, $package$);\n",
"package", GetFilePath(options, file));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment