mirror of
https://github.com/friendica/friendica
synced 2025-04-25 23:10:12 +00:00
Left trim at sign from nicks in ACL
This commit is contained in:
parent
b9c0c114fb
commit
05a5e1792d
2 changed files with 7 additions and 7 deletions
|
@ -627,14 +627,14 @@ function acl_lookup(App $a, $out_type = 'json') {
|
|||
dbesc($search),
|
||||
implode("','", $known_contacts)
|
||||
);
|
||||
if (dbm::is_result($r)){
|
||||
if (dbm::is_result($r)) {
|
||||
foreach ($r as $row) {
|
||||
// nickname..
|
||||
$up = parse_url($row['author-link']);
|
||||
$nick = explode("/",$up['path']);
|
||||
$nick = $nick[count($nick)-1];
|
||||
$nick .= "@".$up['host'];
|
||||
// /nickname
|
||||
$nick = explode('/', $up['path']);
|
||||
// Fix for Mastodon URLs with format https://domain.tld/@nick
|
||||
$nick = ltrim($nick[count($nick) - 1], '@');
|
||||
$nick .= '@' . $up['host'];
|
||||
|
||||
$unknow_contacts[] = array(
|
||||
'type' => 'c',
|
||||
'photo' => proxy_url($row['author-avatar'], false, PROXY_SIZE_MICRO),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue