bordoni / fakerpress

A WordPress plugin that implements an easy way to create fake data inside WordPress.
http://fakerpress.com
Other
338 stars 54 forks source link

Duplicate user emails when making large numbers of users #155

Open CactusWren2020 opened 2 years ago

CactusWren2020 commented 2 years ago

When I make large numbers of users (1000+), some user emails will be duplicated. This is problematic since Wordpress doesn't allow multiple users with the same email.

The rate of duplicate emails may be on the order of 2/1000.

One way of fixing this might be implementing a query for duplicate emails like: select user_email, count(user_email) from wp_users group by user_email having count(user_email)>1;

and then deleting n - (n - 1) of the resulting duplicates.

bordoni commented 2 years ago

Sorry for the huge delay on my answering I had a huge project on the Company I work for that was taking a lot of my time, I will fix this problem.

Something very similar to what you suggested. I actually think this is a great addition. Thanks a lot.