mirror of
https://github.com/flarum/core.git
synced 2025-08-06 08:27:42 +02:00
feat(core): PHP 8.2 Support (#3709)
* chore: test with php 8.2 * chore: bump httphandlerunnder * chore: bump httphandlerunner * chore: address php8.2 deprecation * chore: php 8.2 * chore: bump less.php version * avoid dynamic properties * avoid another dynamic property * Apply fixes from StyleCI * tags php82 * php82 * fix: check for property existence * Rerun checks after s9e/text-formatter update * chore: disable deprecation warnings for php 8.2 * chore: PHP8.2 does not accept dynamic properties * chore: temporarily disable package manager tests workflow Co-authored-by: Sami Mazouz <sychocouldy@gmail.com>
This commit is contained in:
@@ -61,7 +61,7 @@
|
||||
"illuminate/view": "^8.0",
|
||||
"intervention/image": "2.5.* || ^2.6.1",
|
||||
"laminas/laminas-diactoros": "^2.4.1",
|
||||
"laminas/laminas-httphandlerrunner": "^1.2.0",
|
||||
"laminas/laminas-httphandlerrunner": "^1.2.0 || ^2.3.0",
|
||||
"laminas/laminas-stratigility": "^3.2.2",
|
||||
"league/flysystem": "^1.0.11",
|
||||
"matthiasmullie/minify": "^1.3",
|
||||
@@ -84,7 +84,7 @@
|
||||
"symfony/polyfill-intl-messageformatter": "^1.22.0",
|
||||
"symfony/translation": "^5.1.5",
|
||||
"symfony/yaml": "^5.2.2",
|
||||
"wikimedia/less.php": "^3.0"
|
||||
"wikimedia/less.php": "^3.2"
|
||||
},
|
||||
"require-dev": {
|
||||
"flarum/testing": "^1.0.0"
|
||||
|
@@ -113,7 +113,7 @@ class ListNotificationsController extends AbstractListController
|
||||
$ids = [];
|
||||
|
||||
foreach ($notifications as $notification) {
|
||||
if ($notification->subject && isset($notification->subject->discussion_id)) {
|
||||
if ($notification->subject && property_exists($notification->subject, 'discussion_id')) {
|
||||
$ids[] = $notification->subject->discussion_id;
|
||||
}
|
||||
}
|
||||
@@ -121,7 +121,7 @@ class ListNotificationsController extends AbstractListController
|
||||
$discussions = Discussion::query()->find(array_unique($ids));
|
||||
|
||||
foreach ($notifications as $notification) {
|
||||
if ($notification->subject && isset($notification->subject->discussion_id)) {
|
||||
if ($notification->subject && property_exists($notification->subject, 'discussion_id')) {
|
||||
$notification->subject->setRelation('discussion', $discussions->find($notification->subject->discussion_id));
|
||||
}
|
||||
}
|
||||
|
@@ -10,6 +10,7 @@
|
||||
namespace Flarum\Discussion\Event;
|
||||
|
||||
use Flarum\Discussion\UserState;
|
||||
use Flarum\User\User;
|
||||
|
||||
class UserRead
|
||||
{
|
||||
@@ -18,6 +19,11 @@ class UserRead
|
||||
*/
|
||||
public $state;
|
||||
|
||||
/**
|
||||
* @var User
|
||||
*/
|
||||
public $actor;
|
||||
|
||||
/**
|
||||
* @param UserState $state
|
||||
*/
|
||||
|
@@ -14,6 +14,16 @@ use Flarum\Testing\unit\TestCase;
|
||||
|
||||
class ExtensionDependencyResolutionTest extends TestCase
|
||||
{
|
||||
public $tags;
|
||||
public $categories;
|
||||
public $tagBackgrounds;
|
||||
public $something;
|
||||
public $help;
|
||||
public $missing;
|
||||
public $circular1;
|
||||
public $circular2;
|
||||
public $optionalDependencyCategories;
|
||||
|
||||
public function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
Reference in New Issue
Block a user