iachat/spec/lib/integrations/slack
Muhsin Keloth d8da1f5bf3
fix: Handle video file types in Slack file shares (#12630)
Fixes https://linear.app/chatwoot/issue/CW-5752/fix-nomethoderror-when-processing-video-files-in-slack-integration
#### Problem
When users shared video files (like MP4) through Slack, the `file_type`
method in `SlackMessageHelper` would return `nil` for unsupported file
types. This caused a `NoMethodError (undefined method 'to_sym' for nil)`
when the attachment was being processed, as the system expected a symbol
value for the `file_type` attribute.

#### Solution
- Added video file type support in the `file_type` method case statement
- Added `else` clause to default unknown file types to `:file` instead
of returning `nil`
- This ensures `file_type` always returns a symbol, preventing the
`to_sym` error
2025-10-09 21:05:53 +05:30
..
hook_builder_spec.rb Feature: Slack - receive messages, create threads, send replies (#974) 2020-06-22 13:19:26 +05:30
incoming_message_builder_spec.rb fix: Handle video file types in Slack file shares (#12630) 2025-10-09 21:05:53 +05:30
link_unfurl_formatter_spec.rb feat: Slack link unfurling (#7940) 2023-09-29 19:35:56 +05:30
send_on_slack_service_spec.rb feat: Add support for grouped file uploads in Slack (#12454) 2025-09-24 11:31:06 +05:30
slack_link_unfurl_service_spec.rb feat: Slack link unfurling (#7940) 2023-09-29 19:35:56 +05:30