]> git.mxchange.org Git - friendica.git/blobdiff - include/auth.php
Merge pull request #3120 from tobiasd/20170128-editor
[friendica.git] / include / auth.php
index 5dc19d1dfc7eeb1ba0a1e5d7082701a54e6315aa..e3c8d92eebd23f2ae9e6ba33d98f25fcab3ce8ec 100644 (file)
@@ -73,7 +73,7 @@ if (isset($_SESSION) && x($_SESSION,'authenticated') && (!x($_POST,'auth-params'
                        intval($_SESSION['uid'])
                );
 
-               if (!count($r)) {
+               if (!dbm::is_result($r)) {
                        nuke_session();
                        goaway(z_root());
                }
@@ -125,8 +125,7 @@ if (isset($_SESSION) && x($_SESSION,'authenticated') && (!x($_POST,'auth-params'
                                $openid = new LightOpenID;
                                $openid->identity = $openid_url;
                                $_SESSION['openid'] = $openid_url;
-                               $a = get_app();
-                               $openid->returnUrl = $a->get_baseurl(true).'/openid';
+                               $openid->returnUrl = App::get_baseurl(true).'/openid';
                                goaway($openid->authUrl());
                        } catch (Exception $e) {
                                notice(t('We encountered a problem while logging in with the OpenID you provided. Please check the correct spelling of the ID.').'<br /><br >'.t('The error message was:').' '.$e->getMessage());