Sha256: 484fb353f357d0192986d2bc958c666a1e9a65708e89ac9509c13a4a64bd6736
Contents?: true
Size: 530 Bytes
Versions: 1
Compression:
Stored size: 530 Bytes
Contents
class InvitationsController < ApplicationController def edit set_user end def update set_user if @user.update_attributes(user_params) @user.clear_invitation_token! sign_in(:user, @user) redirect_to after_sign_in_path_for(@user), notice: "Welcome to DummyApp!" else render :edit end end private def user_params params.require(:user).permit(:password, :password_confirmation) end def set_user @user = User.find_by_invitation_token(params[:token]) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
self_systeem-0.1.0 | test/dummy_app/app/controllers/invitations_controller.rb |