Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Thomas <nick@gitlab.com>2018-11-14 21:42:36 +0300
committerNick Thomas <nick@gitlab.com>2018-11-19 15:45:07 +0300
commit59c4fb4ecb3aa81ea73a5fe75528ef969c28fa9d (patch)
treec4fb7f51773be8c797b05809081ba50d61e3a338 /lib/gitlab/private_commit_email.rb
parent3eb366722e32d878d56ed09a5fa596b777fccef5 (diff)
Match users better by their private commit email
Private commit emails were introduced in !22560, but some parts of GitLab were not updated to take account of them. This commit adds support in places that were missed.
Diffstat (limited to 'lib/gitlab/private_commit_email.rb')
-rw-r--r--lib/gitlab/private_commit_email.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/gitlab/private_commit_email.rb b/lib/gitlab/private_commit_email.rb
index bade2248ccd..536fc9dae3a 100644
--- a/lib/gitlab/private_commit_email.rb
+++ b/lib/gitlab/private_commit_email.rb
@@ -18,6 +18,10 @@ module Gitlab
match[:id].to_i
end
+ def user_ids_for_emails(emails)
+ emails.map { |email| user_id_for_email(email) }.compact.uniq
+ end
+
def for_user(user)
hostname = Gitlab::CurrentSettings.current_application_settings.commit_email_hostname