diff --git a/app/controllers/settings/users_controller.rb b/app/controllers/settings/users_controller.rb index 94b555102..2e5967528 100644 --- a/app/controllers/settings/users_controller.rb +++ b/app/controllers/settings/users_controller.rb @@ -33,7 +33,8 @@ def get_user def user_params params.require(:user).permit( :email, - :username + :username, + role_ids: [] ) end end diff --git a/spec/requests/settings/users_spec.rb b/spec/requests/settings/users_spec.rb index 64e063350..0ab447eff 100644 --- a/spec/requests/settings/users_spec.rb +++ b/spec/requests/settings/users_spec.rb @@ -27,6 +27,7 @@ expect(response).to be_successful end end + describe "PATCH /update", :as_moderator do let(:user) { create(:user) } @@ -53,5 +54,4 @@ end end end - end