File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 3
3
namespace Statikbe \FilamentFlexibleContentBlockPages ;
4
4
5
5
use Illuminate \Database \Eloquent \Relations \Relation ;
6
+ use Illuminate \Support \Facades \Event ;
6
7
use Mcamara \LaravelLocalization \Facades \LaravelLocalization ;
7
8
use Spatie \LaravelPackageTools \Package ;
8
9
use Spatie \LaravelPackageTools \PackageServiceProvider ;
13
14
use Statikbe \FilamentFlexibleContentBlockPages \Components \LanguageSwitch ;
14
15
use Statikbe \FilamentFlexibleContentBlockPages \Components \Menu ;
15
16
use Statikbe \FilamentFlexibleContentBlockPages \Components \MenuItem ;
17
+ use Statikbe \FilamentFlexibleContentBlockPages \Listeners \SlugChangedListener ;
18
+ use Statikbe \FilamentFlexibleContentBlocks \Events \SlugChanged ;
16
19
use Statikbe \FilamentFlexibleContentBlocks \FilamentFlexibleContentBlocks ;
17
20
18
21
class FilamentFlexibleContentBlockPagesServiceProvider extends PackageServiceProvider
@@ -73,5 +76,8 @@ function ($app) {
73
76
74
77
// set our custom redirector for spatie/laravel-missing-page-redirector
75
78
$ this ->app ->bind (Redirector::class, config ('filament-flexible-content-block-pages.redirects.redirector ' ));
79
+
80
+ // register slug changed listener
81
+ Event::listen (SlugChanged::class, SlugChangedListener::class);
76
82
}
77
83
}
You can’t perform that action at this time.
0 commit comments