summaryrefslogtreecommitdiff
path: root/users/app/controllers
diff options
context:
space:
mode:
Diffstat (limited to 'users/app/controllers')
-rw-r--r--users/app/controllers/users_controller.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/users/app/controllers/users_controller.rb b/users/app/controllers/users_controller.rb
index 320ed96..24db13b 100644
--- a/users/app/controllers/users_controller.rb
+++ b/users/app/controllers/users_controller.rb
@@ -22,7 +22,9 @@ class UsersController < ApplicationController
end
def create
- @user = User.create(params[:user])
+ if @user = User.create(params[:user])
+ flash[:notice] = t(:user_created_successfully)
+ end
respond_with @user
end
@@ -30,7 +32,9 @@ class UsersController < ApplicationController
end
def update
- @user.update_attributes(params[:user])
+ if @user.update_attributes(params[:user])
+ flash[:notice] = t(:user_updated_successfully)
+ end
respond_with @user, :location => edit_user_path(@user)
end