diff --git a/helpers/helpers.go b/helpers/helpers.go index fd9612d..4ec1406 100644 --- a/helpers/helpers.go +++ b/helpers/helpers.go @@ -170,7 +170,7 @@ func isFieldRepeated(f *descriptor.FieldDescriptorProto) bool { func goTypeWithPackage(f *descriptor.FieldDescriptorProto) string { pkg := "" - if *f.Type == descriptor.FieldDescriptorProto_TYPE_MESSAGE { + if *f.Type == descriptor.FieldDescriptorProto_TYPE_MESSAGE || *f.Type == descriptor.FieldDescriptorProto_TYPE_ENUM { pkg = getPackageTypeName(*f.TypeName) } return goType(pkg, f)