Skip to content

Commit e50f363

Browse files
committed
Add 'static' keyword for enums generatef from oneof fields
1 parent a967e6a commit e50f363

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

generator/js_generator.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2259,7 +2259,7 @@ void Generator::GenerateOneofCaseDefinition(
22592259
const std::string className = GetMessagePath(options, oneof->containing_type());
22602260

22612261
const std::string oneofCaseName = options.WantEs6() ? (
2262-
JSOneofName(oneof) + "Case"
2262+
"static " + JSOneofName(oneof) + "Case"
22632263
) : (
22642264
className + "." + JSOneofName(oneof) + "Case"
22652265
);

0 commit comments

Comments
 (0)