Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Citharel <tcit@tcit.fr>2022-02-09 11:43:57 +0300
committerCôme Chilliet (Rebase PR Action) <come-nc@users.noreply.github.com>2022-02-17 16:30:46 +0300
commit6702ff38a79b098c2963c983bca42079451b662c (patch)
treecad4618dc5fa89649664ee5982ffb81961030f22
parentef67f0118c461270bebd6c4f36caf37c8a1d335f (diff)
Ignore contact interaction with self
No need to insert ourselves as a recent contact Signed-off-by: Thomas Citharel <tcit@tcit.fr>
-rw-r--r--apps/contactsinteraction/lib/Listeners/ContactInteractionListener.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/contactsinteraction/lib/Listeners/ContactInteractionListener.php b/apps/contactsinteraction/lib/Listeners/ContactInteractionListener.php
index 21991007ee7..333a6393920 100644
--- a/apps/contactsinteraction/lib/Listeners/ContactInteractionListener.php
+++ b/apps/contactsinteraction/lib/Listeners/ContactInteractionListener.php
@@ -84,6 +84,11 @@ class ContactInteractionListener implements IEventListener {
return;
}
+ if ($event->getUid() !== null && $event->getUid() === $event->getActor()->getUID()) {
+ $this->logger->info("Ignoring contact interaction with self");
+ return;
+ }
+
$existing = $this->mapper->findMatch(
$event->getActor(),
$event->getUid(),