lib/notifiable/notification.rb in notifiable-rails-0.21.1 vs lib/notifiable/notification.rb in notifiable-rails-0.21.2
- old
+ new
@@ -40,23 +40,23 @@
end
notifiers[provider].send_notification(d) if d.is_valid?
end
+ def summarise
+ self.sent_count = self.notification_statuses.count
+ self.gateway_accepted_count = self.notification_statuses.where(:status => 0).count
+ self.save
+ end
+
private
def notifiers
@notifiers ||= {}
end
def close
notifiers.each_value {|n| n.close}
@notifiers = nil
summarise
- end
-
- def summarise
- self.sent_count = self.notification_statuses.count
- self.gateway_accepted_count = self.notification_statuses.where(:status => 0).count
- self.save
end
end
end
\ No newline at end of file