Fix unfollows
This commit is contained in:
parent
9cb690c706
commit
086d487145
3 changed files with 5 additions and 3 deletions
|
@ -2,7 +2,7 @@ class Favourite < ActiveRecord::Base
|
|||
belongs_to :account, inverse_of: :favourites
|
||||
belongs_to :status, inverse_of: :favourites
|
||||
|
||||
has_one :stream_entry, as: :activity, dependent: :destroy
|
||||
has_one :stream_entry, as: :activity
|
||||
|
||||
def verb
|
||||
:favorite
|
||||
|
|
|
@ -2,7 +2,7 @@ class Follow < ActiveRecord::Base
|
|||
belongs_to :account
|
||||
belongs_to :target_account, class_name: 'Account'
|
||||
|
||||
has_one :stream_entry, as: :activity, dependent: :destroy
|
||||
has_one :stream_entry, as: :activity
|
||||
|
||||
validates :account, :target_account, presence: true
|
||||
validates :account_id, uniqueness: { scope: :target_account_id }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue