Add a basic service provider for config overwriting.

This commit is contained in:
Taylor Otwell 2015-01-02 14:47:42 -06:00
parent c7eecb1c91
commit c1db7050ea
3 changed files with 28 additions and 4 deletions

View File

@ -17,14 +17,14 @@ class AppServiceProvider extends ServiceProvider {
/**
* Register any application services.
*
* This service provider is a great spot to register your various container
* bindings with the application. As you can see, we are registering our
* "Registrar" implementation here. You can add your own bindings too!
*
* @return void
*/
public function register()
{
// This service provider is a great spot to register your various container
// bindings with the application. As you can see, we are registering our
// "Registrar" implementation here. You can add your own bindings too!
$this->app->bind(
'Illuminate\Contracts\Auth\Registrar',
'App\Services\Registrar'

View File

@ -0,0 +1,23 @@
<?php namespace App\Providers;
use Illuminate\Support\ServiceProvider;
class ConfigServiceProvider extends ServiceProvider {
/**
* Overwrite any vendor / package configuration.
*
* This service provider is intended to provide a convenient location for you
* to overwrite any "vendor" or package configuration that you may want to
* modify before the application handles the incoming request / command.
*
* @return void
*/
public function register()
{
config([
//
]);
}
}

View File

@ -141,6 +141,7 @@ return [
*/
'App\Providers\AppServiceProvider',
'App\Providers\BusServiceProvider',
'App\Providers\ConfigServiceProvider',
'App\Providers\EventServiceProvider',
'App\Providers\RouteServiceProvider',