diff options
author | friendica <info@friendica.com> | 2012-12-31 15:47:51 -0800 |
---|---|---|
committer | friendica <info@friendica.com> | 2012-12-31 15:47:51 -0800 |
commit | a8812346c4a2962182b66345bf93144bc13c16ad (patch) | |
tree | dd55186b4de5c6d168626fc3a3cd8908e2998093 /mod/follow.php | |
parent | 791302f317de466a079b71e548892c4ffc172005 (diff) | |
download | volse-hubzilla-a8812346c4a2962182b66345bf93144bc13c16ad.tar.gz volse-hubzilla-a8812346c4a2962182b66345bf93144bc13c16ad.tar.bz2 volse-hubzilla-a8812346c4a2962182b66345bf93144bc13c16ad.zip |
couple of fixes to follow, prepare for default connection permissions
Diffstat (limited to 'mod/follow.php')
-rw-r--r-- | mod/follow.php | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/mod/follow.php b/mod/follow.php index 05d1eee73..fd2f8af19 100644 --- a/mod/follow.php +++ b/mod/follow.php @@ -1,21 +1,19 @@ <?php -require_once('Scrape.php'); + require_once('include/follow.php'); function follow_init(&$a) { if(! local_user()) { notice( t('Permission denied.') . EOL); - goaway($_SESSION['return_url']); - // NOTREACHED + return; } $uid = local_user(); $url = notags(trim($_REQUEST['url'])); $return_url = $_SESSION['return_url']; - $result = new_contact($uid,$url,$a->get_channel(),true); if($result['success'] == false) { @@ -26,9 +24,6 @@ function follow_init(&$a) { info( t('Channel added') . EOL); - if(strstr($return_url,'channel')) - goaway($a->get_baseurl() . '/channel/' . $result['channel_id']); + goaway(z_root() . '/connection/' . $result['abook']['abook_id']); - goaway($return_url); - // NOTREACHED } |