acl lookup now works fine as well.

This commit is contained in:
Michael Vogel 2015-10-09 23:27:00 +02:00
parent 16da708e07
commit 1c21401751
1 changed files with 6 additions and 7 deletions

View File

@ -392,7 +392,6 @@ function acl_lookup(&$a, $out_type = 'json') {
if(!local_user())
return "";
$start = (x($_REQUEST,'start')?$_REQUEST['start']:0);
$count = (x($_REQUEST,'count')?$_REQUEST['count']:100);
$search = (x($_REQUEST,'search')?$_REQUEST['search']:"");
@ -492,7 +491,7 @@ function acl_lookup(&$a, $out_type = 'json') {
$groups[] = array(
"type" => "g",
"photo" => "images/twopeople.png",
"name" => $g['name'],
"name" => htmlentities($g['name']),
"id" => intval($g['id']),
"uids" => array_map("intval", explode(",",$g['uids'])),
"link" => '',
@ -547,7 +546,7 @@ function acl_lookup(&$a, $out_type = 'json') {
foreach($r as $g) {
$x['photos'][] = proxy_url($g['micro'], false, PROXY_SIZE_MICRO);
$x['links'][] = $g['url'];
$x['suggestions'][] = $g['name'];
$x['suggestions'][] = htmlentities($g['name']);
$x['data'][] = intval($g['id']);
}
}
@ -560,11 +559,11 @@ function acl_lookup(&$a, $out_type = 'json') {
$contacts[] = array(
"type" => "c",
"photo" => proxy_url($g['micro'], false, PROXY_SIZE_MICRO),
"name" => $g['name'],
"name" => htmlentities($g['name']),
"id" => intval($g['id']),
"network" => $g['network'],
"link" => $g['url'],
"nick" => ($g['attag']) ? $g['attag'] : $g['nick'],
"nick" => htmlentities(($g['attag']) ? $g['attag'] : $g['nick']),
"forum" => $g['forum']
);
}
@ -605,11 +604,11 @@ function acl_lookup(&$a, $out_type = 'json') {
$unknow_contacts[] = array(
"type" => "c",
"photo" => proxy_url($row['author-avatar'], false, PROXY_SIZE_MICRO),
"name" => $row['author-name'],
"name" => htmlentities($row['author-name']),
"id" => '',
"network" => "unknown",
"link" => $row['author-link'],
"nick" => $nick,
"nick" => htmlentities($nick),
"forum" => false
);
}