diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-12-26 21:52:03 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-12-26 21:52:03 +0100 |
commit | 2146ac91a004bad2a6c4dc1d01599a85515928f5 (patch) | |
tree | 0e65a4537c5c33f9e273d8646f1eded0eeb1e38c /app/models/follow_request.rb | |
parent | 3689c119f0ad8d523ab8deb3c2c8ed0a9c84db6e (diff) |
Follow requests send e-mail notifications, but are excluded from notifications API
Better initial state for unlisted/nsfw toggles
Diffstat (limited to 'app/models/follow_request.rb')
-rw-r--r-- | app/models/follow_request.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/app/models/follow_request.rb b/app/models/follow_request.rb index b46065d53..8eef3abf4 100644 --- a/app/models/follow_request.rb +++ b/app/models/follow_request.rb @@ -6,6 +6,8 @@ class FollowRequest < ApplicationRecord belongs_to :account belongs_to :target_account, class_name: 'Account' + has_one :notification, as: :activity, dependent: :destroy + validates :account, :target_account, presence: true validates :account_id, uniqueness: { scope: :target_account_id } |