From e384a9d6caf6b163b9a57f59c55e37e73c09748a Mon Sep 17 00:00:00 2001 From: Hank Grabowski Date: Mon, 13 Feb 2023 17:27:06 -0500 Subject: [PATCH] Automatic PHPCBF style fix --- src/Module/Api/Mastodon/Notifications.php | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/src/Module/Api/Mastodon/Notifications.php b/src/Module/Api/Mastodon/Notifications.php index 82ccd03edf..a1e99a6358 100644 --- a/src/Module/Api/Mastodon/Notifications.php +++ b/src/Module/Api/Mastodon/Notifications.php @@ -84,15 +84,21 @@ class Notifications extends BaseApi } if (in_array(Notification::TYPE_INTRODUCTION, $request['exclude_types'])) { - $condition = DBA::mergeConditions($condition, + $condition = DBA::mergeConditions( + $condition, ["(`vid` != ? OR `type` != ? OR NOT `actor-id` IN (SELECT `id` FROM `contact` WHERE `pending`))", - Verb::getID(Activity::FOLLOW), Post\UserNotification::TYPE_NONE]); + Verb::getID(Activity::FOLLOW), + Post\UserNotification::TYPE_NONE] + ); } if (in_array(Notification::TYPE_FOLLOW, $request['exclude_types'])) { - $condition = DBA::mergeConditions($condition, + $condition = DBA::mergeConditions( + $condition, ["(`vid` != ? OR `type` != ? OR NOT `actor-id` IN (SELECT `id` FROM `contact` WHERE NOT `pending`))", - Verb::getID(Activity::FOLLOW), Post\UserNotification::TYPE_NONE]); + Verb::getID(Activity::FOLLOW), + Post\UserNotification::TYPE_NONE] + ); } if (in_array(Notification::TYPE_LIKE, $request['exclude_types'])) { @@ -134,7 +140,7 @@ class Notifications extends BaseApi $request['limit'] ); - foreach($Notifications as $Notification) { + foreach ($Notifications as $Notification) { try { $mstdnNotifications[] = DI::mstdnNotification()->createFromNotification($Notification, self::appSupportsQuotes()); self::setBoundaries($Notification->id); -- 2.39.5