diff options
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/admin/blog/settings_controller.rb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/app/controllers/admin/blog/settings_controller.rb b/app/controllers/admin/blog/settings_controller.rb index 52a7e83..541fa36 100644 --- a/app/controllers/admin/blog/settings_controller.rb +++ b/app/controllers/admin/blog/settings_controller.rb @@ -4,7 +4,14 @@ class Admin::Blog::SettingsController < Admin::BaseController @recipients = BlogComment::Notification.recipients if request.post? - BlogComment::Notification.recipients == params[:recipients] + BlogComment::Notification.recipients = params[:recipients] + flash[:notice] = t('admin.blog.settings.notification_recipients.updated', + :recipients => BlogComment::Notification.recipients) + unless request.xhr? or from_dialog? + redirect_back_or_default(admin_blog_posts_path) + else + render :text => "<script type='text/javascript'>parent.window.location = '#{admin_blog_posts_path}';</script>" + end end end |