| 
									
										
										
										
											2015-08-17 01:59:23 +08:00
										 |  |  | <?php | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-09-11 02:31:09 +08:00
										 |  |  | namespace BookStack\Providers; | 
					
						
							| 
									
										
										
										
											2015-08-17 01:59:23 +08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-12-12 01:29:33 +08:00
										 |  |  | use BookStack\Actions\ActivityLogger; | 
					
						
							| 
									
										
										
										
											2019-09-20 07:18:28 +08:00
										 |  |  | use BookStack\Auth\Permissions\PermissionService; | 
					
						
							| 
									
										
										
										
											2021-03-17 01:14:03 +08:00
										 |  |  | use BookStack\Theming\ThemeService; | 
					
						
							| 
									
										
										
										
											2018-09-25 23:58:03 +08:00
										 |  |  | use BookStack\Uploads\ImageService; | 
					
						
							| 
									
										
										
										
											2015-08-17 01:59:23 +08:00
										 |  |  | use Illuminate\Support\ServiceProvider; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | class CustomFacadeProvider extends ServiceProvider | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * Bootstrap the application services. | 
					
						
							|  |  |  |      * | 
					
						
							|  |  |  |      * @return void | 
					
						
							|  |  |  |      */ | 
					
						
							|  |  |  |     public function boot() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         //
 | 
					
						
							|  |  |  |     } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * Register the application services. | 
					
						
							|  |  |  |      * | 
					
						
							|  |  |  |      * @return void | 
					
						
							|  |  |  |      */ | 
					
						
							|  |  |  |     public function register() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2019-09-20 07:18:28 +08:00
										 |  |  |         $this->app->singleton('activity', function () { | 
					
						
							| 
									
										
										
										
											2021-12-12 01:29:33 +08:00
										 |  |  |             return $this->app->make(ActivityLogger::class); | 
					
						
							| 
									
										
										
										
											2015-08-17 01:59:23 +08:00
										 |  |  |         }); | 
					
						
							| 
									
										
										
										
											2015-08-30 22:31:16 +08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2019-09-20 07:18:28 +08:00
										 |  |  |         $this->app->singleton('images', function () { | 
					
						
							| 
									
										
										
										
											2019-03-31 00:54:15 +08:00
										 |  |  |             return $this->app->make(ImageService::class); | 
					
						
							| 
									
										
										
										
											2015-12-10 03:50:17 +08:00
										 |  |  |         }); | 
					
						
							| 
									
										
										
										
											2019-09-20 07:18:28 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  |         $this->app->singleton('permissions', function () { | 
					
						
							|  |  |  |             return $this->app->make(PermissionService::class); | 
					
						
							|  |  |  |         }); | 
					
						
							| 
									
										
										
										
											2021-03-17 01:14:03 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  |         $this->app->singleton('theme', function () { | 
					
						
							|  |  |  |             return $this->app->make(ThemeService::class); | 
					
						
							|  |  |  |         }); | 
					
						
							| 
									
										
										
										
											2015-08-17 01:59:23 +08:00
										 |  |  |     } | 
					
						
							|  |  |  | } |