X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Ffollow.php;h=adc3fcc3bd5125465e4c3a0720053869360f8cfb;hb=a09273802ef0b790c0374a2fece6cded5686ebc2;hp=04c279c5b6ab707f5995aa0c229e412613082d50;hpb=a97b540ebb3f1d5bb5c18b4c0fb631443d03b5a7;p=friendica.git diff --git a/mod/follow.php b/mod/follow.php index 04c279c5b6..adc3fcc3bd 100644 --- a/mod/follow.php +++ b/mod/follow.php @@ -20,12 +20,12 @@ function follow_post(App $a) } if (isset($_REQUEST['cancel'])) { - goaway('contacts'); + $a->internalRedirect('contacts'); } $uid = local_user(); $url = notags(trim($_REQUEST['url'])); - $return_url = 'contacts'; + $return_path = 'contacts'; // Makes the connection request for friendica contacts easier // This is just a precaution if maybe this page is called somewhere directly via POST @@ -37,24 +37,24 @@ function follow_post(App $a) if ($result['message']) { notice($result['message']); } - goaway($return_url); + $a->internalRedirect($return_path); } elseif ($result['cid']) { - goaway('contacts/' . $result['cid']); + $a->internalRedirect('contact/' . $result['cid']); } info(L10n::t('The contact could not be added.')); - goaway($return_url); + $a->internalRedirect($return_path); // NOTREACHED } function follow_content(App $a) { - $return_url = 'contacts'; + $return_path = 'contacts'; if (!local_user()) { notice(L10n::t('Permission denied.')); - goaway($return_url); + $a->internalRedirect($return_path); // NOTREACHED } @@ -74,7 +74,7 @@ function follow_content(App $a) if ($r[0]['pending']) { notice(L10n::t('You already added this contact.')); $submit = ''; - //goaway($_SESSION['return_url']); + //$a->internalRedirect($_SESSION['return_path']); // NOTREACHED } } @@ -84,21 +84,21 @@ function follow_content(App $a) if (($ret['network'] == Protocol::DIASPORA) && !Config::get('system', 'diaspora_enabled')) { notice(L10n::t("Diaspora support isn't enabled. Contact can't be added.")); $submit = ''; - //goaway($_SESSION['return_url']); + //$a->internalRedirect($_SESSION['return_path']); // NOTREACHED } if (($ret['network'] == Protocol::OSTATUS) && Config::get('system', 'ostatus_disabled')) { notice(L10n::t("OStatus support is disabled. Contact can't be added.")); $submit = ''; - //goaway($_SESSION['return_url']); + //$a->internalRedirect($_SESSION['return_path']); // NOTREACHED } if ($ret['network'] == Protocol::PHANTOM) { notice(L10n::t("The network type couldn't be detected. Contact can't be added.")); $submit = ''; - //goaway($_SESSION['return_url']); + //$a->internalRedirect($_SESSION['return_path']); // NOTREACHED } @@ -118,7 +118,7 @@ function follow_content(App $a) if (!$r) { notice(L10n::t('Permission denied.')); - goaway($return_url); + $a->internalRedirect($return_path); // NOTREACHED }