Sha256: 1c84d249f9e4ea502e1b273b697193a78a64a1e2aed026a3b6579d5af2e957d2
Contents?: true
Size: 488 Bytes
Versions: 1
Compression:
Stored size: 488 Bytes
Contents
class Auth::RegisteredUserController < ApplicationController skip_authentication def new render inertia: 'Auth/Register' end def create form = Auth::RegisterForm.new params.permit(:name, :email, :password, :password_confirmation) return redirect_to register_path, inertia: { errors: form.error_messages } if form.invalid? user = User.create(name: form.name, email: form.email, password: form.password) login user redirect_to dashboard_path end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
kaze-0.5.0 | stubs/inertia-common/app/controllers/auth/registered_user_controller.rb |