Skip to content

Commit

Permalink
explicitely define recipients_ids as attributes, try to fix foodcoops…
Browse files Browse the repository at this point in the history
  • Loading branch information
mortbauer committed Mar 8, 2024
1 parent c6f6c10 commit bcde771
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions plugins/messages/app/models/message.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ class Message < ApplicationRecord
has_many :message_recipients, dependent: :destroy
has_many :recipients, through: :message_recipients, source: :user

attribute :recipients_ids

attr_accessor :send_method, :recipient_tokens, :order_id

scope :threads, -> { where(reply_to: nil) }
Expand Down

2 comments on commit bcde771

@lentschi
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mortbauer Shouldn't this rather be self.ignored_columns += [:recipients_ids]?

@mortbauer
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have already removed this again after I dug more into it.

Please sign in to comment.