don't include archived contacts in public posts, unless specifically requested
This commit is contained in:
parent
d46436dc9c
commit
764e0201ce
@ -295,8 +295,8 @@ function contact_remove($channel_id, $abook_id) {
|
|||||||
|
|
||||||
$archive = get_pconfig($channel_id, 'system','archive_removed_contacts');
|
$archive = get_pconfig($channel_id, 'system','archive_removed_contacts');
|
||||||
if($archive) {
|
if($archive) {
|
||||||
q("update abook set abook_flags = abook_flags | %d where abook_id = %d and abook_channel = %d limit 1",
|
q("update abook set abook_flags = ( abook_flags | %d ) where abook_id = %d and abook_channel = %d limit 1",
|
||||||
intval(ABOOK_FLAG_ARCHIVE),
|
intval(ABOOK_FLAG_ARCHIVED),
|
||||||
intval($abook_id),
|
intval($abook_id),
|
||||||
intval($channel_id)
|
intval($channel_id)
|
||||||
);
|
);
|
||||||
|
@ -31,10 +31,11 @@ function collect_recipients($item,&$private) {
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$recipients = array();
|
$recipients = array();
|
||||||
$r = q("select * from abook where abook_channel = %d and not (abook_flags & %d) and not (abook_flags & %d)",
|
$r = q("select * from abook where abook_channel = %d and not (abook_flags & %d) and not (abook_flags & %d) and not (abook_flags & %d)",
|
||||||
intval($item['uid']),
|
intval($item['uid']),
|
||||||
intval(ABOOK_FLAG_SELF),
|
intval(ABOOK_FLAG_SELF),
|
||||||
intval(ABOOK_FLAG_PENDING)
|
intval(ABOOK_FLAG_PENDING),
|
||||||
|
intval(ABOOK_FLAG_ARCHIVED)
|
||||||
);
|
);
|
||||||
if($r) {
|
if($r) {
|
||||||
foreach($r as $rr) {
|
foreach($r as $rr) {
|
||||||
|
Reference in New Issue
Block a user