// We need to extract the basebath from the profile url
// to redirect the visitors '/magic' module.
- // Note: We should have the basepath of a contact also in the contact table.
- $urlarr = explode('/profile/', $contact['url']);
- $basepath = $urlarr[0];
+ $basepath = Contact::getBasepath($contact['url']);
if ($basepath != $a->getBaseURL() && !strstr($dest, '/magic') && !strstr($dest, '/rmagic')) {
$magic_path = $basepath . '/magic' . '?f=&owa=1&dest=' . $dest;
use Friendica\BaseModule;
use Friendica\Core\Authentication;
+use Friendica\Core\Cache;
use Friendica\Core\Hook;
use Friendica\Core\L10n;
use Friendica\Core\System;
$visitor_home = null;
if (remote_user()) {
$visitor_home = Profile::getMyURL();
+ Cache::delete('zrlInit:' . $visitor_home);
}
Hook::callAll("logging_out");