Class: UsersController

Inherits:
ApplicationController show all
Defined in:
app/controllers/users_controller.rb

Instance Method Summary collapse

Instance Method Details

#showObject



4
5
# File 'app/controllers/users_controller.rb', line 4

def show
end

#updateObject



7
8
9
10
11
12
13
# File 'app/controllers/users_controller.rb', line 7

def update
  unless @user.update_attributes(user_params)
    return render :show
  end
  session[:password] = user_params[:password]
  redirect_to user_path, notice: I18n.t("messages.password_successfully_updated")
end