mirror of
https://github.com/friendica/friendica
synced 2025-04-27 07:10:12 +00:00
Archive and unarchive contacts
This commit is contained in:
parent
370cf6bd91
commit
ca41e9154d
2 changed files with 6 additions and 1 deletions
|
@ -99,7 +99,7 @@ class Contact extends BaseObject
|
|||
if ($contact['archive']) {
|
||||
return;
|
||||
}
|
||||
|
||||
logger('Blubb-m: '.$contact['id'].' - '.System::callstack());
|
||||
if ($contact['term-date'] <= NULL_DATE) {
|
||||
dba::update('contact', array('term-date' => datetime_convert()), array('id' => $contact['id']));
|
||||
|
||||
|
@ -139,6 +139,7 @@ class Contact extends BaseObject
|
|||
*/
|
||||
public static function unmarkForArchival(array $contact)
|
||||
{
|
||||
//logger('Blubb-m: '.$contact['id'].' - '.System::callstack());
|
||||
$condition = array('`id` = ? AND (`term-date` > ? OR `archive`)', $contact[`id`], NULL_DATE);
|
||||
$exists = dba::exists('contact', $condition);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue