Removed lines I've added

This commit is contained in:
Samuel Hawksby-Robinson 2020-07-20 22:44:22 +01:00 committed by Andrea Maria Piana
parent ae1e6db883
commit db517eb1f4
No known key found for this signature in database
GPG Key ID: AA6CCA6DE0E06424
1 changed files with 0 additions and 3 deletions

View File

@ -122,7 +122,6 @@ func (m *Message) MarshalJSON() ([]byte, error) {
Hash string `json:"hash"` Hash string `json:"hash"`
Pack int32 `json:"pack"` Pack int32 `json:"pack"`
} }
item := struct { item := struct {
ID string `json:"id"` ID string `json:"id"`
WhisperTimestamp uint64 `json:"whisperTimestamp"` WhisperTimestamp uint64 `json:"whisperTimestamp"`
@ -176,7 +175,6 @@ func (m *Message) MarshalJSON() ([]byte, error) {
MessageType: m.MessageType, MessageType: m.MessageType,
CommandParameters: m.CommandParameters, CommandParameters: m.CommandParameters,
} }
if sticker := m.GetSticker(); sticker != nil { if sticker := m.GetSticker(); sticker != nil {
item.Sticker = &StickerAlias{ item.Sticker = &StickerAlias{
Pack: sticker.Pack, Pack: sticker.Pack,
@ -207,7 +205,6 @@ func (m *Message) UnmarshalJSON(data []byte) error {
if err := json.Unmarshal(data, &aux); err != nil { if err := json.Unmarshal(data, &aux); err != nil {
return err return err
} }
if aux.ContentType == protobuf.ChatMessage_STICKER { if aux.ContentType == protobuf.ChatMessage_STICKER {
m.Payload = &protobuf.ChatMessage_Sticker{Sticker: aux.Sticker} m.Payload = &protobuf.ChatMessage_Sticker{Sticker: aux.Sticker}
} }