diff options
Diffstat (limited to 'include/zot.php')
-rw-r--r-- | include/zot.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/zot.php b/include/zot.php index 7bdde836f..2bc54e6f3 100644 --- a/include/zot.php +++ b/include/zot.php @@ -1532,7 +1532,7 @@ function process_delivery($sender,$arr,$deliveries,$relay,$public = false,$reque } } - if($arr['item_restrict'] & ITEM_DELETED) { + if(intval($arr['item_deleted'])) { // remove_community_tag is a no-op if this isn't a community tag activity remove_community_tag($sender,$arr,$channel['channel_id']); @@ -1549,14 +1549,14 @@ function process_delivery($sender,$arr,$deliveries,$relay,$public = false,$reque continue; } - $r = q("select id, edited, item_restrict, item_flags, mid, parent_mid from item where mid = '%s' and uid = %d limit 1", + $r = q("select * from item where mid = '%s' and uid = %d limit 1", dbesc($arr['mid']), intval($channel['channel_id']) ); if($r) { // We already have this post. $item_id = $r[0]['id']; - if($r[0]['item_restrict'] & ITEM_DELETED) { + if(intval($r[0]['item_deleted'])) { // It was deleted locally. $result[] = array($d['hash'],'update ignored',$channel['channel_name'] . ' <' . $channel['channel_address'] . '@' . get_app()->get_hostname() . '>',$arr['mid']); continue; @@ -1686,7 +1686,7 @@ function delete_imported_item($sender,$item,$uid) { logger('delete_imported_item invoked',LOGGER_DEBUG); - $r = q("select id, item_restrict from item where ( author_xchan = '%s' or owner_xchan = '%s' or source_xchan = '%s' ) + $r = q("select id, item_deleted from item where ( author_xchan = '%s' or owner_xchan = '%s' or source_xchan = '%s' ) and mid = '%s' and uid = %d limit 1", dbesc($sender['hash']), dbesc($sender['hash']), @@ -1700,7 +1700,7 @@ function delete_imported_item($sender,$item,$uid) { return false; } - if($r[0]['item_restrict'] & ITEM_DELETED) { + if(intval($r[0]['item_deleted'])) { logger('delete_imported_item: item was already deleted'); return false; } |