7 lines
233 B
Text
7 lines
233 B
Text
- if @user.valid?
|
|
:plain
|
|
new Flash("Username successfully changed", "notice")
|
|
- else
|
|
- error = @user.errors.full_messages.first
|
|
:plain
|
|
new Flash("Username change failed - #{escape_javascript error.html_safe}", "alert")
|