Sha256: 56949918a3897044e0b0ea7a29821a0c14b4f59b395ed53bf6d6ee7f813bf1fb

Contents?: true

Size: 368 Bytes

Versions: 5

Compression:

Stored size: 368 Bytes

Contents

class PasswordController < ApplicationController
  def update
    form = UpdatePasswordForm.new params.permit(:current_password, :password, :password_confirmation)

    return redirect_to profile_edit_path, inertia: { errors: form.error_messages } if form.invalid?

    Current.user.update(password: form.password)

    redirect_back_or_to profile_edit_path
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
kaze-0.5.0 stubs/inertia-common/app/controllers/password_controller.rb
kaze-0.4.0 stubs/inertia-common/app/controllers/password_controller.rb
kaze-0.3.0 stubs/inertia-common/app/controllers/password_controller.rb
kaze-0.2.0 stubs/default/app/controllers/password_controller.rb
kaze-0.1.0 stubs/default/app/controllers/password_controller.rb