diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-07 21:06:24 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-07 21:06:24 +0300 |
commit | eadb77d89f5f7d445bfd326f18873168f4719f12 (patch) | |
tree | 207af6741c0f99f17345c1a28bc0c356740fefee /app/models/list.rb | |
parent | 31040b5bfe48f8d73830f473513164427522b3a6 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/list.rb')
-rw-r--r-- | app/models/list.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/list.rb b/app/models/list.rb index b53e2fb7c33..13c42b55bf7 100644 --- a/app/models/list.rb +++ b/app/models/list.rb @@ -50,7 +50,7 @@ class List < ApplicationRecord list_ids = items.map { |i| i[:list_id] } user_ids = items.map { |i| i[:user_id] } - ListUserPreference.where(list_id: list_ids, user_id: user_ids).find_each do |preference| + ListUserPreference.where(list_id: list_ids.uniq, user_id: user_ids.uniq).find_each do |preference| loader.call({ list_id: preference.list_id, user_id: preference.user_id }, preference) end end |