diff --git a/extensions/pusher/src/Api/Controller/AuthController.php b/extensions/pusher/src/Api/Controller/AuthController.php index 1ff53847f..e5af7588b 100644 --- a/extensions/pusher/src/Api/Controller/AuthController.php +++ b/extensions/pusher/src/Api/Controller/AuthController.php @@ -45,7 +45,8 @@ class AuthController implements ControllerInterface $pusher = new Pusher( $this->settings->get('flarum-pusher.app_key'), $this->settings->get('flarum-pusher.app_secret'), - $this->settings->get('flarum-pusher.app_id') + $this->settings->get('flarum-pusher.app_id'), + ['cluster' => $this->settings->get('flarum-pusher.app_cluster')] ); $payload = json_decode($pusher->socket_auth($userChannel, array_get($body, 'socket_id')), true); diff --git a/extensions/pusher/src/Listener/AddPusherApi.php b/extensions/pusher/src/Listener/AddPusherApi.php index 9d9f93245..ce778e91c 100755 --- a/extensions/pusher/src/Listener/AddPusherApi.php +++ b/extensions/pusher/src/Listener/AddPusherApi.php @@ -49,7 +49,7 @@ class AddPusherApi { if ($event->isSerializer(ForumSerializer::class)) { $event->attributes['pusherKey'] = $this->settings->get('flarum-pusher.app_key'); - $event->attributes['pusherCluster'] = $this->settings->get('flarum-pusher.app_cluster', 'us'); + $event->attributes['pusherCluster'] = $this->settings->get('flarum-pusher.app_cluster'); } }