From 947478ca760d8a59753d9139592ea623a49a3f08 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Mon, 6 Feb 2017 14:10:54 -0800 Subject: don't add zid to app links if they're on this system and we're logged in already. This messes up the null arg detection in mod_network. --- Zotlabs/Lib/Apps.php | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'Zotlabs/Lib/Apps.php') diff --git a/Zotlabs/Lib/Apps.php b/Zotlabs/Lib/Apps.php index e40c7ef0e..ee1458aba 100644 --- a/Zotlabs/Lib/Apps.php +++ b/Zotlabs/Lib/Apps.php @@ -146,8 +146,11 @@ class Apps { $ret['type'] = 'system'; foreach($ret as $k => $v) { - if(strpos($v,'http') === 0) - $ret[$k] = zid($v); + if(strpos($v,'http') === 0) { + if(! (local_channel() && strpos($v,z_root()) === 0)) { + $ret[$k] = zid($v); + } + } } if(array_key_exists('desc',$ret)) @@ -280,8 +283,11 @@ class Apps { $papp['url'] = z_root() . ((strpos($papp['url'],'/') === 0) ? '' : '/') . $papp['url']; foreach($papp as $k => $v) { - if(strpos($v,'http') === 0 && $k != 'papp') - $papp[$k] = zid($v); + if(strpos($v,'http') === 0 && $k != 'papp') { + if(! (local_channel() && strpos($v,z_root()) === 0)) { + $papp[$k] = zid($v); + } + } if($k === 'desc') $papp['desc'] = str_replace(array('\'','"'),array(''','&dquot;'),$papp['desc']); -- cgit v1.2.3