Sha256: 9a4aabb3da53d258860f4706d4bfb674b3cec4d27d9a16c130268baea60e5426
Contents?: true
Size: 496 Bytes
Versions: 20
Compression:
Stored size: 496 Bytes
Contents
module Rostra module EmailNotifier def self.included(base) base.after_create :notify_followers end private # Send email notification to everyone who is following the question. Of course, # don't send notification to the person that created the answer/comment. # def notify_followers question.notified_followers.each do |user| next if self.user == user ApplicationMailer.notification(user, question).deliver end end end end
Version data entries
20 entries across 20 versions & 1 rubygems