/** * Register any other events for your application. * * @param \Illuminate\Contracts\Events\Dispatcher $events */ public function boot(DispatcherContract $events) { parent::boot($events); Article::observe(DetachCategoriesBeforeArticleDelete::class); Media::observe(UploadFileWhenAddingMedia::class); Media::observe(RemoveFileWhenDeletingMedia::class); Series::observe(RemoveArticlesWhenDeletingSeries::class); Category::observe(DetachArticlesWhenDeletingCategory::class); }