From fd7658a70af6b2a61c0fa3f75c5aec3281080873 Mon Sep 17 00:00:00 2001 From: Michael Date: Sat, 21 Apr 2018 10:39:46 +0000 Subject: [PATCH] Contact requests from Diaspora for private forums aren't accepted automatically anymore --- src/Protocol/Diaspora.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Protocol/Diaspora.php b/src/Protocol/Diaspora.php index 8120fea8a5..e81c53499f 100644 --- a/src/Protocol/Diaspora.php +++ b/src/Protocol/Diaspora.php @@ -1173,7 +1173,7 @@ class Diaspora // Yes, then it is fine. return true; // Is it a post to a community? - } elseif (($contact["rel"] == CONTACT_IS_FOLLOWER) && ($importer["page-flags"] == PAGE_COMMUNITY)) { + } elseif (($contact["rel"] == CONTACT_IS_FOLLOWER) && in_array($importer["page-flags"], [PAGE_COMMUNITY, PAGE_PRVGROUP])) { // That's good return true; // Is the message a global user or a comment? @@ -2665,7 +2665,7 @@ class Diaspora Contact::updateAvatar($ret["photo"], $importer['uid'], $contact_record["id"], true); - if ($importer["page-flags"] == PAGE_NORMAL) { + if (in_array($importer["page-flags"], [PAGE_NORMAL, PAGE_PRVGROUP])) { logger("Sending intra message for author ".$author.".", LOGGER_DEBUG); $hash = random_string().(string)time(); // Generate a confirm_key