summaryrefslogtreecommitdiff
path: root/lib/gitlab/bitbucket_server_import
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2018-07-28 22:25:10 -0700
committerStan Hu <stanhu@gmail.com>2018-07-28 22:25:10 -0700
commit7b23b5500583abdc9b3f53724e6f3fb5238f3449 (patch)
treea74e38c36ff65ae521217366b972b54d90cb466e /lib/gitlab/bitbucket_server_import
parenta5722c378bc88984657372267c16bb57168c02af (diff)
downloadgitlab-ce-7b23b5500583abdc9b3f53724e6f3fb5238f3449.tar.gz
Restrict to confirmed users and allow memoization of unkonwn e-mails
Diffstat (limited to 'lib/gitlab/bitbucket_server_import')
-rw-r--r--lib/gitlab/bitbucket_server_import/importer.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gitlab/bitbucket_server_import/importer.rb b/lib/gitlab/bitbucket_server_import/importer.rb
index f5febd266cb..0da572f24fc 100644
--- a/lib/gitlab/bitbucket_server_import/importer.rb
+++ b/lib/gitlab/bitbucket_server_import/importer.rb
@@ -64,8 +64,8 @@ module Gitlab
return users[email] if users.key?(email)
- user = User.find_by_any_email(email)
- users[email] = user&.id if user
+ user = User.find_by_any_email(email, confirmed: true)
+ users[email] = user&.id
user&.id
end