Can not login if User already registerd self with same email .
-
I’ve created a problem for my client LIFT. I made them a Woocommerce store through which many users had registered themselves. I use External Login, using LIFT’s external database of people so LIFT admin can log in to the dashboard and current LIFT members can log in to enjoy cheaper prices at the store. I have discovered that members can not log in if they had happened to have already registered themselves with a different username (typically firstname.lastname format) using their same email address that is in our membership database! It fails silently but I figured out that the failure is because each user must have a unique email in WordPress. I just fixed this for existing users with this:
UPDATE wordpress.wp_users A
INNER JOIN lift.person B ON A.user_email = B.email
SET A.user_login = B.idHowever, to make this problem really go away – it would be great if when External Login tries to update the wp database and can’t because the same email already exists – it would go ahead and update the record with the matching email address, changing the user_login to the id from the external database as required.
Is this an issue you’ve come across before? Would this be an easy change, feature, option?
- The topic ‘Can not login if User already registerd self with same email .’ is closed to new replies.