mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 06:14:12 +08:00
FEATURE: phase 1 of supporting multiple email addresses
This commit is contained in:

committed by
Guo Xiang Tan

parent
739794f0cb
commit
d0b027d88d
@ -324,7 +324,7 @@ class ImportScripts::Base
|
||||
rescue => e
|
||||
# try based on email
|
||||
if e.try(:record).try(:errors).try(:messages).try(:[], :email).present?
|
||||
if existing = User.find_by(email: opts[:email].downcase)
|
||||
if existing = User.find_by_email(opts[:email].downcase)
|
||||
existing.custom_fields["import_id"] = import_id
|
||||
existing.save!
|
||||
u = existing
|
||||
|
Reference in New Issue
Block a user