From 50f9195f2d26882292c18a168a63e046cc5fda10 Mon Sep 17 00:00:00 2001 From: CaIon Date: Sat, 9 Aug 2025 21:04:49 +0800 Subject: [PATCH] feat: remove custom JSON marshaling for Message struct --- dto/openai_request.go | 8 -------- 1 file changed, 8 deletions(-) diff --git a/dto/openai_request.go b/dto/openai_request.go index 127c5c94..f33b2c1e 100644 --- a/dto/openai_request.go +++ b/dto/openai_request.go @@ -140,14 +140,6 @@ type Message struct { //parsedStringContent *string } -func (m *Message) MarshalJSON() ([]byte, error) { - if m.Content == nil { - m.Content = "" - } - type Alias Message - return json.Marshal((*Alias)(m)) -} - type MediaContent struct { Type string `json:"type"` Text string `json:"text,omitempty"`