mirror of
https://github.com/friendica/friendica
synced 2025-04-22 15:10:12 +00:00
Improved notification for announced posts
This commit is contained in:
parent
2b05561337
commit
27a306185a
2 changed files with 6 additions and 39 deletions
|
@ -406,21 +406,6 @@ class UserNotification
|
|||
return true;
|
||||
}
|
||||
|
||||
// The following check doesn't make sense on activities, so quit here
|
||||
if ($item['verb'] == Activity::ANNOUNCE) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check if the contact is a mentioned forum
|
||||
$tags = DBA::select('tag-view', ['url'], ['uri-id' => $item['uri-id'], 'type' => [Tag::MENTION, Tag::EXCLUSIVE_MENTION]]);
|
||||
while ($tag = DBA::fetch($tags)) {
|
||||
$condition = ['nurl' => Strings::normaliseLink($tag['url']), 'uid' => $uid, 'notify_new_posts' => true, 'contact-type' => Contact::TYPE_COMMUNITY];
|
||||
if (DBA::exists('contact', $condition)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
DBA::close($tags);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue