X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fuser.php;h=23023abd65122901045c4b11244fe29186951b05;hb=4487515d0c8dc295e5f8b7a137accfa741b5cf52;hp=282bbdbba24761acc46d6a9bfeb78b25cf725678;hpb=9c7d5d42e1dc3370a4d371472175e17bc505e5ca;p=friendica.git diff --git a/include/user.php b/include/user.php index 282bbdbba2..23023abd65 100644 --- a/include/user.php +++ b/include/user.php @@ -7,6 +7,7 @@ require_once('include/text.php'); require_once('include/pgettext.php'); require_once('include/datetime.php'); + function create_user($arr) { // Required: { username, nickname, email } or { openid_url } @@ -59,7 +60,13 @@ function create_user($arr) { $openid->returnUrl = $a->get_baseurl() . '/openid'; $openid->required = array('namePerson/friendly', 'contact/email', 'namePerson'); $openid->optional = array('namePerson/first','media/image/aspect11','media/image/default'); - goaway($openid->authUrl()); + try { + $authurl = $openid->authUrl(); + } catch (Exception $e){ + $result['message'] .= t("We encountered a problem while logging in with the OpenID you provided. Please check the correct spelling of the ID."). EOL . EOL . t("The error message was:") . $e->getMessage() . EOL; + return $result; + } + goaway($authurl); // NOTREACHED }