From db5e9b7f99fbc9b26a2f696535b8194b2f5a6610 Mon Sep 17 00:00:00 2001 From: Manfred Touron Date: Sun, 10 Feb 2019 19:50:23 +0100 Subject: [PATCH] fix: fix 'int64*Extension' helpers --- helpers/helpers.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/helpers/helpers.go b/helpers/helpers.go index 3c408fa..4726b44 100644 --- a/helpers/helpers.go +++ b/helpers/helpers.go @@ -389,7 +389,7 @@ func int64FieldExtension(fieldID int32, f *descriptor.FieldDescriptorProto) int6 return 0 } var extendedType *descriptor.FieldOptions - var extensionType *string + var extensionType *int64 eds := proto.RegisteredExtensions(f.Options) if eds[fieldID] == nil { @@ -397,7 +397,7 @@ func int64FieldExtension(fieldID int32, f *descriptor.FieldDescriptorProto) int6 ExtendedType: extendedType, ExtensionType: extensionType, Field: fieldID, - Tag: fmt.Sprintf("bytes,%d", fieldID), + Tag: fmt.Sprintf("varint,%d", fieldID), } proto.RegisterExtension(ed) eds = proto.RegisteredExtensions(f.Options) @@ -424,7 +424,7 @@ func int64MessageExtension(fieldID int32, f *descriptor.DescriptorProto) int64 { return 0 } var extendedType *descriptor.MessageOptions - var extensionType *string + var extensionType *int64 eds := proto.RegisteredExtensions(f.Options) if eds[fieldID] == nil { @@ -432,7 +432,7 @@ func int64MessageExtension(fieldID int32, f *descriptor.DescriptorProto) int64 { ExtendedType: extendedType, ExtensionType: extensionType, Field: fieldID, - Tag: fmt.Sprintf("bytes,%d", fieldID), + Tag: fmt.Sprintf("varint,%d", fieldID), } proto.RegisterExtension(ed) eds = proto.RegisteredExtensions(f.Options)