noosfero | Revert "scrap: Fix constant name"

Antonio Terceiro gitlab at gitlab.com
Wed Feb 25 12:34:12 BRT 2015


Antonio Terceiro pushed to refs/heads/master at <a href="https://gitlab.com/noosfero/noosfero">Noosfero / noosfero</a>

Commits:
<a href="https://gitlab.com/noosfero/noosfero/commit/661d4188f87e5f0a47f5960c87c6a63a5b89e93c">661d4188</a> by Antonio Terceiro
Revert "scrap: Fix constant name"

This reverts commit 926442b6d0c469ce6c73d5e32cf9c686e0fca5b4.

- - - - -


Changes:

=====================================
app/mailers/scrap_notifier.rb
=====================================
--- a/app/mailers/scrap_notifier.rb
+++ b/app/mailers/scrap_notifier.rb
@@ -1,4 +1,4 @@
-class ScrapNotifier < ActionMailer::Base
+class Scrap::Notifier < ActionMailer::Base
   def notification(scrap)
     sender, receiver = scrap.sender, scrap.receiver
     @recipient = receiver.name

=====================================
app/models/scrap.rb
=====================================
--- a/app/models/scrap.rb
+++ b/app/models/scrap.rb
@@ -25,7 +25,7 @@ class Scrap < ActiveRecord::Base
 
   after_create do |scrap|
     scrap.root.update_attribute('updated_at', DateTime.now) unless scrap.root.nil?
-    ScrapNotifier.notification(scrap).deliver if scrap.send_notification?
+    Scrap::Notifier.notification(scrap).deliver if scrap.send_notification?
   end
 
   before_validation :strip_all_html_tags

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20150225/d203679a/attachment.html>


More information about the Noosfero-dev mailing list