Skip to content
Snippets Groups Projects
Unverified Commit 656e4057 authored by Ahmad Farhat's avatar Ahmad Farhat Committed by GitHub
Browse files

Fixed 400 with share room and merge user (#2448)

parent 957bf88a
Branches
Tags
No related merge requests found
......@@ -209,13 +209,12 @@ class AdminsController < ApplicationController
initial_list = User.without_role(:super_admin)
.where.not(uid: current_user.uid)
.merge_list_search(params[:search])
.pluck_to_hash(:uid, :name, :email)
initial_list = initial_list.where(provider: @user_domain) if Rails.configuration.loadbalanced_configuration
# Respond with JSON object of users
respond_to do |format|
format.json { render body: initial_list.to_json }
format.json { render body: initial_list.pluck_to_hash(:uid, :name, :email).to_json }
end
end
......
......@@ -212,13 +212,12 @@ class UsersController < ApplicationController
initial_list = User.where.not(uid: params[:owner_uid])
.with_role(roles_can_appear)
.shared_list_search(params[:search])
.pluck_to_hash(:uid, :name)
initial_list = initial_list.where(provider: @user_domain) if Rails.configuration.loadbalanced_configuration
# Respond with JSON object of users
respond_to do |format|
format.json { render body: initial_list.to_json }
format.json { render body: initial_list.pluck_to_hash(:uid, :name).to_json }
end
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment