如何允许Joomla 2.5中的重复电子邮件地址无效

I have a simple problem, that I cant seem to solve.

I have commented out:

// check for existing email
$query->clear();
$query->select($this->_db->quoteName('id'));
$query->from($this->_db->quoteName('#__users'));
$query->where($this->_db->quoteName('email') . ' = ' . $this->_db->quote($this->email));
$query->where($this->_db->quoteName('id') . ' != ' . (int) $this->id);
$this->_db->setQuery($query);
$xid = intval($this->_db->loadResult());
//if ($xid && $xid != intval($this->id))
//{
//  $this->setError(JText::_('JLIB_DATABASE_ERROR_EMAIL_INUSE'));
//  return false;
//}

but when a user navigates to "http://www.website.com/index.php/component/users/profile?layout=edit"

if 2 users have the same email address it wont let them edit the profile. If you click submit, it just refreshes the page and doesnt update anything.

Is there a way that the "edit profile" page can bypass the duplicate email check?