mirror of
https://github.com/discourse/discourse.git
synced 2025-09-06 10:50:21 +08:00
Lots of ugprades to the Disqus importer script
This commit is contained in:
parent
6af4e6bd05
commit
72d7c055f4
2 changed files with 100 additions and 80 deletions
|
@ -274,7 +274,7 @@ class ImportScripts::Base
|
|||
merge = opts.delete(:merge)
|
||||
post_create_action = opts.delete(:post_create_action)
|
||||
|
||||
existing = User.where(email: opts[:email].downcase, username: opts[:username]).first
|
||||
existing = User.where("email = ? OR username = ?", opts[:email].downcase, opts[:username]).first
|
||||
return existing if existing && (merge || existing.custom_fields["import_id"].to_i == import_id.to_i)
|
||||
|
||||
bio_raw = opts.delete(:bio_raw)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue