protobuf definitions for hyper-real-time chat
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

add more optional fields

+16 -12
+14 -10
gen/go/lrc.pb.go
··· 757 757 758 758 type Get struct { 759 759 state protoimpl.MessageState `protogen:"open.v1"` 760 - Topic string `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"` 761 - Connected uint32 `protobuf:"varint,2,opt,name=connected,proto3" json:"connected,omitempty"` 760 + Topic *string `protobuf:"bytes,1,opt,name=topic,proto3,oneof" json:"topic,omitempty"` 761 + Connected *uint32 `protobuf:"varint,2,opt,name=connected,proto3,oneof" json:"connected,omitempty"` 762 762 unknownFields protoimpl.UnknownFields 763 763 sizeCache protoimpl.SizeCache 764 764 } ··· 794 794 } 795 795 796 796 func (x *Get) GetTopic() string { 797 - if x != nil { 798 - return x.Topic 797 + if x != nil && x.Topic != nil { 798 + return *x.Topic 799 799 } 800 800 return "" 801 801 } 802 802 803 803 func (x *Get) GetConnected() uint32 { 804 - if x != nil { 805 - return x.Connected 804 + if x != nil && x.Connected != nil { 805 + return *x.Connected 806 806 } 807 807 return 0 808 808 } ··· 1113 1113 "\x05color\x18\x03 \x01(\rH\x02R\x05color\x88\x01\x01B\a\n" + 1114 1114 "\x05_nickB\r\n" + 1115 1115 "\v_externalIDB\b\n" + 1116 - "\x06_color\"9\n" + 1117 - "\x03Get\x12\x14\n" + 1118 - "\x05topic\x18\x01 \x01(\tR\x05topic\x12\x1c\n" + 1119 - "\tconnected\x18\x02 \x01(\rR\tconnected\">\n" + 1116 + "\x06_color\"[\n" + 1117 + "\x03Get\x12\x19\n" + 1118 + "\x05topic\x18\x01 \x01(\tH\x00R\x05topic\x88\x01\x01\x12!\n" + 1119 + "\tconnected\x18\x02 \x01(\rH\x01R\tconnected\x88\x01\x01B\b\n" + 1120 + "\x06_topicB\f\n" + 1121 + "\n" + 1122 + "_connected\">\n" + 1120 1123 "\x04Sudo\x12\x1e\n" + 1121 1124 "\n" + 1122 1125 "externalID\x18\x01 \x01(\tR\n" + ··· 1218 1221 (*Event_Unban)(nil), 1219 1222 } 1220 1223 file_lrc_proto_msgTypes[9].OneofWrappers = []any{} 1224 + file_lrc_proto_msgTypes[10].OneofWrappers = []any{} 1221 1225 type x struct{} 1222 1226 out := protoimpl.TypeBuilder{ 1223 1227 File: protoimpl.DescBuilder{
+2 -2
lrc.proto
··· 58 58 } 59 59 60 60 message Get { 61 - string topic = 1; 62 - uint32 connected = 2; 61 + optional string topic = 1; 62 + optional uint32 connected = 2; 63 63 } 64 64 65 65 message Sudo {