summaryrefslogtreecommitdiff
path: root/app/controllers/api/users_controller.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/api/users_controller.rb')
-rw-r--r--app/controllers/api/users_controller.rb11
1 files changed, 10 insertions, 1 deletions
diff --git a/app/controllers/api/users_controller.rb b/app/controllers/api/users_controller.rb
index 709e076..cb7b7bc 100644
--- a/app/controllers/api/users_controller.rb
+++ b/app/controllers/api/users_controller.rb
@@ -53,7 +53,7 @@ module Api
end
def update
- @user.account.update params[:user]
+ @user.account.update user_update_params
respond_with @user
end
@@ -67,6 +67,15 @@ module Api
private
+ def user_update_params
+ params.require(:user).permit :login,
+ :password_verifier,
+ :password_salt,
+ :recovery_code_verifier,
+ :recovery_code_salt,
+ :public_key
+ end
+
def release_handles
current_user.is_monitor? || params[:identities] == "destroy"
end