Commit 9db1abf5 authored by Dries's avatar Dries

- Patch #165642 by Damien Tournoud et al: fixed SQL error.

parent 5ebbdd0c
......@@ -1367,8 +1367,11 @@ function user_login_submit($form, &$form_state) {
function user_external_login_register($name, $module) {
global $user;
$user = user_load(array('name' => $name));
if (!isset($user->uid)) {
$existing_user = user_load(array('name' => $name));
if (isset($existing_user->uid)) {
$user = $existing_user;
}
else {
// Register this new user.
$userinfo = array(
'name' => $name,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment