#472: Update Users::SettingsController
This commit is contained in:
parent
5595936c48
commit
42e6aeaede
|
@ -40,7 +40,7 @@ class Users::SettingsController < Users::BaseController
|
|||
|
||||
def notifiers
|
||||
if request.patch?
|
||||
if @user.notifier.update_attributes(params[:settings_notifier])
|
||||
if @user.notifier.update_attributes(settings_notifier_params)
|
||||
flash[:notice] = I18n.t("flash.settings.saved")
|
||||
redirect_to notifiers_settings_path and return
|
||||
end
|
||||
|
@ -61,6 +61,10 @@ class Users::SettingsController < Users::BaseController
|
|||
|
||||
private
|
||||
|
||||
def settings_notifier_params
|
||||
subject_params(SettingsNotifier)
|
||||
end
|
||||
|
||||
def user_params
|
||||
subject_params(User)
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue