diaspora/app/models/notifications/commented.rb
2017-09-17 19:29:15 +02:00

17 lines
418 B
Ruby

# frozen_string_literal: true
module Notifications
module Commented
extend ActiveSupport::Concern
def deleted_translation_key
"notifications.also_commented_deleted"
end
module ClassMethods
def mention_notification_exists?(comment, recipient_person)
Notifications::MentionedInComment.exists?(target: comment.mentions.where(person: recipient_person))
end
end
end
end