Commit 17ac0fd5 authored by Phil Hughes's avatar Phil Hughes

Improved Ruby code in autocomplete user search

parent 548f48ef
...@@ -55,7 +55,7 @@ class AutocompleteController < ApplicationController ...@@ -55,7 +55,7 @@ class AutocompleteController < ApplicationController
def find_users def find_users
@users = @users =
if @project if @project
user_ids = @project.team.users.map(&:id) user_ids = @project.team.users.pluck(:id)
if params[:author_id].present? if params[:author_id].present?
user_ids << params[:author_id] user_ids << params[:author_id]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment