Updated rollbar package

This commit is contained in:
snipe 2021-03-09 16:16:57 -08:00
parent 7e56fc5e0d
commit c3871c98df
3 changed files with 18 additions and 8 deletions

View file

@ -52,7 +52,7 @@ class AppServiceProvider extends ServiceProvider
public function register()
{
if (($this->app->environment('production')) && (config('services.rollbar.access_token'))){
if (($this->app->environment('production')) && (config('logging.channels.rollbar.access_token'))) {
$this->app->register(\Rollbar\Laravel\RollbarServiceProvider::class);
}

View file

@ -2,7 +2,7 @@
use Monolog\Handler\StreamHandler;
return [
$config = [
/*
|--------------------------------------------------------------------------
@ -44,6 +44,7 @@ return [
'level' => env('APP_LOG_LEVEL', 'error'),
],
'daily' => [
'driver' => 'daily',
'path' => storage_path('logs/laravel.log'),
@ -51,6 +52,13 @@ return [
'days' => env('APP_LOG_MAX_FILES', 5),
],
'rollbar' => [
'driver' => 'monolog',
'handler' => \Rollbar\Laravel\MonologHandler::class,
'access_token' => env('ROLLBAR_TOKEN'),
'level' => env('APP_LOG_LEVEL', 'debug'),
],
'slack' => [
'driver' => 'slack',
'url' => env('LOG_SLACK_WEBHOOK_URL'),
@ -85,3 +93,10 @@ return [
],
];
if ((env('APP_ENV')=='production') && env('ROLLBAR_TOKEN')) {
array_push($config['channels']['stack']['channels'], 'rollbar');
}
return $config;

View file

@ -49,12 +49,7 @@ return [
'app_key' => env('STUNNING_APP_KEY'),
'stripe_id' => env('STUNNING_STRIPE_ID'),
],
'rollbar' => [
'access_token' => env('ROLLBAR_TOKEN'),
'level' => env('ROLLBAR_LEVEL', 'error'),
],
'google' => [
'maps_api_key' => env('GOOGLE_MAPS_API')
],