X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fopenid.php;h=7300c686b4b209695cb719cad00847894e536267;hb=41663c7592abe55a958632c3a48265e0a8544d2b;hp=209960ee58b44968bd0c65d010e3824631f41856;hpb=d577ab98eb0f28f9f807795f54c87d80ef9c0dc2;p=friendica.git diff --git a/mod/openid.php b/mod/openid.php index 209960ee58..7300c686b4 100644 --- a/mod/openid.php +++ b/mod/openid.php @@ -8,7 +8,6 @@ use Friendica\Core\Authentication; use Friendica\Core\Config; use Friendica\Core\L10n; use Friendica\Core\Logger; -use Friendica\Core\System; use Friendica\Database\DBA; use Friendica\Util\Strings; @@ -20,7 +19,7 @@ function openid_content(App $a) { Logger::log('mod_openid ' . print_r($_REQUEST,true), Logger::DATA); - if((x($_GET,'openid_mode')) && (x($_SESSION,'openid'))) { + if(!empty($_GET['openid_mode']) && !empty($_SESSION['openid'])) { $openid = new LightOpenID($a->getHostName()); @@ -64,7 +63,7 @@ function openid_content(App $a) { // Successful OpenID login - but we can't match it to an existing account. // New registration? - if (intval(Config::get('config', 'register_policy')) === REGISTER_CLOSED) { + if (intval(Config::get('config', 'register_policy')) === \Friendica\Module\Register::CLOSED) { notice(L10n::t('Account not found and OpenID registration is not permitted on this site.') . EOL); $a->internalRedirect(); } @@ -94,17 +93,17 @@ function openid_content(App $a) { } } } - if ($nick) { + if (!empty($nick)) { $args .= '&nickname=' . urlencode($nick); } - elseif ($first) { + elseif (!empty($first)) { $args .= '&nickname=' . urlencode($first); } - if ($photosq) { + if (!empty($photosq)) { $args .= '&photo=' . urlencode($photosq); } - elseif ($photo) { + elseif (!empty($photo)) { $args .= '&photo=' . urlencode($photo); }