Tiny tweaks on codebase

This commit is contained in:
Pig Fang 2019-08-08 17:21:15 +08:00
parent eae0c07ff6
commit 28f80a2ef0
5 changed files with 23 additions and 48 deletions

View File

@ -13,6 +13,19 @@ use Illuminate\Support\ServiceProvider;
class AppServiceProvider extends ServiceProvider
{
/**
* Register any application services.
*
* @return void
*/
public function register()
{
$this->app->singleton('cipher', 'App\Services\Cipher\\'.config('secure.cipher'));
$this->app->singleton('options', \App\Services\Option::class);
$this->app->singleton('parsedown', \Parsedown::class);
$this->app->singleton('webpack', \App\Services\Webpack::class);
}
/**
* Bootstrap any application services.
*
@ -63,19 +76,6 @@ class AppServiceProvider extends ServiceProvider
// @codeCoverageIgnoreEnd
}
/**
* Register any application services.
*
* @return void
*/
public function register()
{
$this->app->singleton('cipher', 'App\Services\Cipher\\'.config('secure.cipher'));
$this->app->singleton('options', \App\Services\Option::class);
$this->app->singleton('parsedown', \Parsedown::class);
$this->app->singleton('webpack', \App\Services\Webpack::class);
}
/**
* Configure the \Illuminate\Routing\UrlGenerator.
*

View File

@ -11,6 +11,16 @@ use Illuminate\Support\ServiceProvider;
class PluginServiceProvider extends ServiceProvider
{
/**
* Register any application services.
*
* @return void
*/
public function register()
{
$this->app->singleton('plugins', PluginManager::class);
}
/**
* Bootstrap any application services.
*
@ -83,16 +93,6 @@ class PluginServiceProvider extends ServiceProvider
});
}
/**
* Register any application services.
*
* @return void
*/
public function register()
{
$this->app->singleton('plugins', PluginManager::class);
}
/**
* Register class autoloader for plugins.
*

View File

@ -54,14 +54,4 @@ class ResponseMacroServiceProvider extends ServiceProvider
], $header));
});
}
/**
* Register any application services.
*
* @return void
*/
public function register()
{
//
}
}

View File

@ -40,14 +40,4 @@ class RuntimeCheckServiceProvider extends ServiceProvider
return true;
}
/**
* Register any application services.
*
* @return void
*/
public function register()
{
//
}
}

View File

@ -46,9 +46,4 @@ class ValidatorExtendServiceProvider extends ServiceProvider
return preg_match($regexp, $value);
});
}
public function register()
{
//
}
}