nil pointer dereference fix (#37) #38

Merged
skobkin merged 1 commit from fix_quoted_messages_usernames_context into main 2024-11-03 22:43:05 +00:00

View file

@ -99,7 +99,7 @@ func chatMessageToOpenAiChatCompletionMessage(message ChatMessage) openai.ChatCo
func chatMessageToText(message ChatMessage) string { func chatMessageToText(message ChatMessage) string {
var msgText string var msgText string
if message.ReplyTo == nil { if message.ReplyTo != nil {
Review

😆

😆
msgText += "In reply to:" msgText += "In reply to:"
msgText += quoteText(presentUserMessageAsText(*message.ReplyTo)) + "\n\n" msgText += quoteText(presentUserMessageAsText(*message.ReplyTo)) + "\n\n"
} }