delete reaction notifications when deleting status
This commit is contained in:
parent
c31b59012e
commit
81a12e2c18
1 changed files with 2 additions and 0 deletions
|
@ -16,6 +16,8 @@ class StatusReaction < ApplicationRecord
|
||||||
belongs_to :status, inverse_of: :status_reactions
|
belongs_to :status, inverse_of: :status_reactions
|
||||||
belongs_to :custom_emoji, optional: true
|
belongs_to :custom_emoji, optional: true
|
||||||
|
|
||||||
|
has_one :notification, as: :activity, dependent: :destroy
|
||||||
|
|
||||||
validates :name, presence: true
|
validates :name, presence: true
|
||||||
validates_with StatusReactionValidator
|
validates_with StatusReactionValidator
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue