Merge pull request #11354 from MrPetovan/bug/notices
Check array key existence in ActivityPub\Transmitter::createPermissionBlockForItem
This commit is contained in:
commit
677cbf8aea
|
@ -529,7 +529,7 @@ class Transmitter
|
||||||
$parent = Post::selectFirst(['causer-link', 'post-reason'], ['id' => $item['parent']]);
|
$parent = Post::selectFirst(['causer-link', 'post-reason'], ['id' => $item['parent']]);
|
||||||
if (($parent['post-reason'] == Item::PR_ANNOUNCEMENT) && !empty($parent['causer-link'])) {
|
if (($parent['post-reason'] == Item::PR_ANNOUNCEMENT) && !empty($parent['causer-link'])) {
|
||||||
$profile = APContact::getByURL($parent['causer-link'], false);
|
$profile = APContact::getByURL($parent['causer-link'], false);
|
||||||
$is_forum_thread = ($profile['type'] == 'Group');
|
$is_forum_thread = isset($profile['type']) && $profile['type'] == 'Group';
|
||||||
} else {
|
} else {
|
||||||
$is_forum_thread = false;
|
$is_forum_thread = false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user