From 7a6d95f70ccb12d61355ecd677eff40dd13260b7 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 14 Oct 2016 02:28:49 +0200 Subject: E-mail preferences page --- app/controllers/settings_controller.rb | 27 --------------------------- 1 file changed, 27 deletions(-) delete mode 100644 app/controllers/settings_controller.rb (limited to 'app/controllers/settings_controller.rb') diff --git a/app/controllers/settings_controller.rb b/app/controllers/settings_controller.rb deleted file mode 100644 index 299e1f3bc..000000000 --- a/app/controllers/settings_controller.rb +++ /dev/null @@ -1,27 +0,0 @@ -class SettingsController < ApplicationController - layout 'auth' - - before_action :authenticate_user! - before_action :set_account - - def show - end - - def update - if @account.update(account_params) - redirect_to settings_path, notice: 'Changes successfully saved!' - else - render action: :show - end - end - - private - - def account_params - params.require(:account).permit(:display_name, :note, :avatar, :header) - end - - def set_account - @account = current_user.account - end -end -- cgit