fix: Attach instagram images with file type story_mentions (#4100)

This commit is contained in:
Tejaswini Chile
2022-03-10 20:27:30 +05:30
committed by GitHub
parent b3545f42f1
commit 647efa12e7
11 changed files with 219 additions and 18 deletions

View File

@@ -34,7 +34,7 @@ class Attachment < ApplicationRecord
has_one_attached :file
validate :acceptable_file
enum file_type: [:image, :audio, :video, :file, :location, :fallback]
enum file_type: [:image, :audio, :video, :file, :location, :fallback, :share, :story_mention]
def push_event_data
return unless file_type

View File

@@ -64,7 +64,7 @@ class Message < ApplicationRecord
# [:deleted] : Used to denote whether the message was deleted by the agent
# [:external_created_at] : Can specify if the message was created at a different timestamp externally
store :content_attributes, accessors: [:submitted_email, :items, :submitted_values, :email, :in_reply_to, :deleted,
:external_created_at], coder: JSON
:external_created_at, :story_sender, :story_id], coder: JSON
store :external_source_ids, accessors: [:slack], coder: JSON, prefix: :external_source_id