1
1
Fork 0

Revert adding a leading slash to redir links

This commit is contained in:
Hypolite Petovan 2016-12-04 21:31:28 -05:00
parent 979fc6d38a
commit 5e20aed428

View file

@ -1187,7 +1187,7 @@ function redir_private_images($a, &$item)
} }
if ((local_user() == $item['uid']) && ($item['private'] != 0) && ($item['contact-id'] != $a->contact['id']) && ($item['network'] == NETWORK_DFRN)) { if ((local_user() == $item['uid']) && ($item['private'] != 0) && ($item['contact-id'] != $a->contact['id']) && ($item['network'] == NETWORK_DFRN)) {
$img_url = '/redir?f=1&quiet=1&url=' . urlencode($mtch[1]) . '&conurl=' . urlencode($item['author-link']); $img_url = 'redir?f=1&quiet=1&url=' . urlencode($mtch[1]) . '&conurl=' . urlencode($item['author-link']);
$item['body'] = str_replace($mtch[0], '[img]' . $img_url . '[/img]', $item['body']); $item['body'] = str_replace($mtch[0], '[img]' . $img_url . '[/img]', $item['body']);
} }
} }