1
0
mirror of https://github.com/flarum/core.git synced 2025-08-13 03:44:32 +02:00

Get rid of event subscribers that resolve services too early, part 1

Refs flarum/core#1578.
This commit is contained in:
Franz Liedke
2018-12-15 17:26:25 +01:00
parent bdf94f9218
commit 42b86cd3c1
2 changed files with 3 additions and 14 deletions

View File

@@ -9,6 +9,7 @@
* file that was distributed with this source code.
*/
use Flarum\Api\Event\Serializing;
use Flarum\Extend;
use Flarum\Pusher\Api\Controller\AuthController;
use Flarum\Pusher\Listener;
@@ -26,7 +27,7 @@ return [
->post('/pusher/auth', 'pusher.auth', AuthController::class),
function (Dispatcher $events) {
$events->subscribe(Listener\AddPusherApi::class);
$events->listen(Serializing::class, Listener\AddPusherApi::class);
$events->subscribe(Listener\PushNewPosts::class);
},
];