]> git.mxchange.org Git - friendica.git/blobdiff - src/Model/Profile.php
Renamed System::redirect() to $a->redirect()
[friendica.git] / src / Model / Profile.php
index f6fb3167d775cbe33d23dee5dfe296c4e335acc0..52ec5ccf0850570e3598f04145334f540fb01a40 100644 (file)
@@ -1047,7 +1047,7 @@ class Profile
                // Try to avoid recursion - but send them home to do a proper magic auth.
                $query = str_replace(array('?zrl=', '&zid='), array('?rzrl=', '&rzrl='), $a->query_string);
                // The other instance needs to know where to redirect.
-               $dest = urlencode(System::baseUrl() . '/' . $query);
+               $dest = urlencode($a->getBaseURL() . '/' . $query);
 
                // We need to extract the basebath from the profile url
                // to redirect the visitors '/magic' module.
@@ -1055,14 +1055,14 @@ class Profile
                $urlarr = explode('/profile/', $contact['url']);
                $basepath = $urlarr[0];
 
-               if ($basepath != System::baseUrl() && !strstr($dest, '/magic') && !strstr($dest, '/rmagic')) {
+               if ($basepath != $a->getBaseURL() && !strstr($dest, '/magic') && !strstr($dest, '/rmagic')) {
                        $magic_path = $basepath . '/magic' . '?f=&owa=1&dest=' . $dest;
 
                        // We have to check if the remote server does understand /magic without invoking something
                        $serverret = Network::curl($basepath . '/magic');
                        if ($serverret->isSuccess()) {
                                logger('Doing magic auth for visitor ' . $my_url . ' to ' . $magic_path, LOGGER_DEBUG);
-                               goaway($magic_path);
+                               $a->redirect($magic_path);
                        }
                }
        }