From 101cb1255d6de637c5ea621df253a4628a9109ab Mon Sep 17 00:00:00 2001 From: Franz Liedke Date: Wed, 26 Sep 2018 23:11:27 +0200 Subject: [PATCH] Let extensions take care of flushing the formatter cache --- .../src/Formatter/FormatterServiceProvider.php | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/framework/core/src/Formatter/FormatterServiceProvider.php b/framework/core/src/Formatter/FormatterServiceProvider.php index 25de9fe55..8ed73457b 100644 --- a/framework/core/src/Formatter/FormatterServiceProvider.php +++ b/framework/core/src/Formatter/FormatterServiceProvider.php @@ -11,23 +11,11 @@ namespace Flarum\Formatter; -use Flarum\Extension\Event\Disabled; -use Flarum\Extension\Event\Enabled; use Flarum\Foundation\AbstractServiceProvider; use Illuminate\Contracts\Container\Container; -use Illuminate\Contracts\Events\Dispatcher; class FormatterServiceProvider extends AbstractServiceProvider { - /** - * {@inheritdoc} - */ - public function boot(Dispatcher $events) - { - $events->listen(Enabled::class, [$this, 'flushFormatter']); - $events->listen(Disabled::class, [$this, 'flushFormatter']); - } - /** * {@inheritdoc} */ @@ -43,9 +31,4 @@ class FormatterServiceProvider extends AbstractServiceProvider $this->app->alias('flarum.formatter', Formatter::class); } - - public function flushFormatter() - { - $this->app->make('flarum.formatter')->flush(); - } }