Move vaCentral config to its own config file and ServiceProvider
This commit is contained in:
19
app/Providers/vaCentralServiceProvider.php
Executable file
19
app/Providers/vaCentralServiceProvider.php
Executable file
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
namespace App\Providers;
|
||||
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
use VaCentral\VaCentral;
|
||||
|
||||
/**
|
||||
* Bootstrap the vaCentral library
|
||||
* @package App\Providers
|
||||
*/
|
||||
class vaCentralServiceProvider extends ServiceProvider
|
||||
{
|
||||
public function boot()
|
||||
{
|
||||
if(filled(config('vacentral.api_key'))) {
|
||||
VaCentral::setApiKey(config('vacentral.api_key'));
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user