From 67a0e97f7cb2636a798d8e14e72d65335e0e1020 Mon Sep 17 00:00:00 2001 From: Michael Date: Mon, 25 Nov 2019 08:49:14 +0000 Subject: [PATCH] Avoid contact update for non federated networks --- src/Model/Contact.php | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/Model/Contact.php b/src/Model/Contact.php index d7e05f6e8b..765c440646 100644 --- a/src/Model/Contact.php +++ b/src/Model/Contact.php @@ -1459,11 +1459,15 @@ class Contact extends BaseObject $contact_id = $contact["id"]; // Update the contact every 7 days - $update_contact = ($contact['updated'] < DateTimeFormat::utc('now -7 days')); + if (in_array($contact['network'], Protocol::NATIVE_SUPPORT)) { + $update_contact = ($contact['updated'] < DateTimeFormat::utc('now -7 days')); - // We force the update if the avatar is empty - if (empty($contact['avatar'])) { - $update_contact = true; + // We force the update if the avatar is empty + if (empty($contact['avatar'])) { + $update_contact = true; + } + } else { + $update_contact = false; } // Update the contact in the background if needed but it is called by the frontend -- 2.39.5