]> git.mxchange.org Git - friendica.git/blobdiff - src/Model/Contact.php
Remove contacts in the background
[friendica.git] / src / Model / Contact.php
index 39a0ba718a8cd0b2d78c78a38e5dbbae9515f0e1..b18159d40cf0cf823bba43b082e6d897af214b9c 100644 (file)
@@ -314,15 +314,10 @@ class Contact extends BaseObject
                        return;
                }
 
-               $archive = PConfig::get($contact['uid'], 'system', 'archive_removed_contacts');
-               if ($archive) {
-                       DBA::update('contact', ['archive' => true, 'network' => 'none', 'writable' => false], ['id' => $id]);
-                       return;
-               }
-
-               DBA::delete('contact', ['id' => $id]);
+               // Archive the contact
+               DBA::update('contact', ['archive' => true, 'network' => Protocol::PHANTOM], ['id' => $id]);
 
-               // Delete the rest in the background
+               // Delete it in the background
                Worker::add(PRIORITY_LOW, 'RemoveContact', $id);
        }