forked from science-ation/science-ation
- Don't collide emails with the existing user being saved
This commit is contained in:
parent
5a4daf5580
commit
689369d460
@ -91,7 +91,7 @@
|
||||
|
||||
/* Check for an email collision */
|
||||
$em = mysql_escape_string(stripslashes($_POST['email']));
|
||||
$q=mysql_query("SELECT id FROM users WHERE email='$em'");
|
||||
$q=mysql_query("SELECT id FROM users WHERE email='$em' AND id!='{$u['id']}'");
|
||||
if(mysql_num_rows($q) > 0) {
|
||||
$notice = 'email_exists';
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user