修复竞赛处不能留言问题

This commit is contained in:
z9hang 2014-06-19 14:44:58 +08:00
parent f2cb1390da
commit 3e37a54a0f
1 changed files with 6 additions and 1 deletions

View File

@ -75,7 +75,12 @@ class Mailer < ActionMailer::Base
return -1
end
mail :to => journals_for_message.jour.author.mail, :subject => @title
else
elsif journals_for_message.jour.class.to_s.to_sym == :Contest
if !journals_for_message.jour.author.notify_about? journals_for_message
return -1
end
mail :to => journals_for_message.jour.author.mail, :subject => @title
else
mail :to => @mail.mail, :subject => @title
end