fix: Consider the emails where in-reply-to header has multiple values (#7715)
- Return the first message id for now to avoid the errors and subsequently missing the message. - Use .last instead of .first to avoid expensive query. - Fix array response in response bot. Fixes: https://linear.app/chatwoot/issue/CW-2358/activerecordstatementinvalid-pgdatatypemismatch-error-argument-of-and
This commit is contained in:
@@ -61,7 +61,7 @@ class Enterprise::MessageTemplates::ResponseBotService
|
||||
end
|
||||
|
||||
def create_messages(response, conversation)
|
||||
response = process_response_content(response)
|
||||
response = process_response_content(response).first
|
||||
create_outgoing_message(response, conversation)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user