fix photos page permissions

This commit is contained in:
rabuzarus 2016-11-14 18:49:51 +01:00
commit 9878974e1f
5 changed files with 51 additions and 51 deletions

View file

@ -1896,21 +1896,21 @@ function drop_item($id,$interactive = true) {
$owner = $item['uid'];
$cid = 0;
$contact_id = 0;
// check if logged in user is either the author or owner of this item
if (is_array($_SESSION['remote'])) {
foreach($_SESSION['remote'] as $visitor) {
if ($visitor['uid'] == $item['uid'] && $visitor['cid'] == $item['contact-id']) {
$cid = $visitor['cid'];
$contact_id = $visitor['cid'];
break;
}
}
}
if ((local_user() == $item['uid']) || ($cid) || (! $interactive)) {
if ((local_user() == $item['uid']) || ($contact_id) || (! $interactive)) {
// Check if we should do HTML-based delete confirmation
if ($_REQUEST['confirm']) {