acl issue with some ActivityPub completions

This commit is contained in:
zotlabs 2017-09-17 23:54:40 -07:00
parent 1d9e0f17a6
commit 5c379b4d35

View File

@ -21,7 +21,7 @@ class Acl extends \Zotlabs\Web\Controller {
function init() { function init() {
// logger('mod_acl: ' . print_r($_REQUEST,true)); logger('mod_acl: ' . print_r($_REQUEST,true));
$start = (x($_REQUEST,'start') ? $_REQUEST['start'] : 0); $start = (x($_REQUEST,'start') ? $_REQUEST['start'] : 0);
$count = (x($_REQUEST,'count') ? $_REQUEST['count'] : 500); $count = (x($_REQUEST,'count') ? $_REQUEST['count'] : 500);
@ -307,7 +307,7 @@ class Acl extends \Zotlabs\Web\Controller {
$contacts[] = array( $contacts[] = array(
"photo" => $g['photo'], "photo" => $g['photo'],
"name" => $g['name'], "name" => $g['name'],
"nick" => $g['address'], "nick" => $g['address']
); );
} }
} }
@ -331,6 +331,11 @@ class Acl extends \Zotlabs\Web\Controller {
$g['hash'] = urlencode($g['hash']); $g['hash'] = urlencode($g['hash']);
if(! $g['nick']) {
$t = explode(' ',strtolower($g['name']));
$g['nick'] = $t[0] . '@';
}
if(in_array($g['hash'],$permitted) && $type == 'c' && (! $noforums)) { if(in_array($g['hash'],$permitted) && $type == 'c' && (! $noforums)) {
$contacts[] = array( $contacts[] = array(
"type" => "c", "type" => "c",