mirror of
https://github.com/flarum/framework.git
synced 2024-11-26 02:10:09 +08:00
Support cluster setting on backend
This commit is contained in:
parent
64d349a5b6
commit
8de87cc5cc
|
@ -78,10 +78,17 @@ class PushNewPosts
|
||||||
*/
|
*/
|
||||||
protected function getPusher()
|
protected function getPusher()
|
||||||
{
|
{
|
||||||
|
$options = [];
|
||||||
|
|
||||||
|
if ($cluster = $this->settings->get('flarum-pusher.app_cluster')) {
|
||||||
|
$options['cluster'] = $cluster;
|
||||||
|
}
|
||||||
|
|
||||||
return new Pusher(
|
return new Pusher(
|
||||||
$this->settings->get('flarum-pusher.app_key'),
|
$this->settings->get('flarum-pusher.app_key'),
|
||||||
$this->settings->get('flarum-pusher.app_secret'),
|
$this->settings->get('flarum-pusher.app_secret'),
|
||||||
$this->settings->get('flarum-pusher.app_id')
|
$this->settings->get('flarum-pusher.app_id'),
|
||||||
|
$options
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user