fix: message_type inconsistency across message end points (#10108)
The `before_type_cast` method sometimes returns a string for `message_type`, creating inconsistencies in different payloads. This pull request will remove all `before_type_cast` usage and replace it with `to_i` methods.
This commit is contained in:
@@ -26,6 +26,7 @@ RSpec.describe 'Public Inbox Contact Conversation Messages API', type: :request
|
||||
expect(response).to have_http_status(:success)
|
||||
data = response.parsed_body
|
||||
expect(data['content']).to eq('hello')
|
||||
expect(data['message_type']).to eq(0)
|
||||
end
|
||||
|
||||
it 'does not create the message' do
|
||||
|
||||
Reference in New Issue
Block a user