Class: Accountly::UsernamesController

Inherits:
AccountController show all
Defined in:
app/controllers/accountly/usernames_controller.rb

Instance Method Summary collapse

Instance Method Details

#createObject



13
14
15
16
17
18
19
20
# File 'app/controllers/accountly/usernames_controller.rb', line 13

def create
  @username_form = UsernameForm.new(current_user)
  if @username_form.submit( params[:username_form] )
    redirect_to settings_url, notice: t('.notice.success')
  else
    render "new"
  end
end

#newObject



9
10
11
# File 'app/controllers/accountly/usernames_controller.rb', line 9

def new
  @username_form = UsernameForm.new(current_user)
end