We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8c64294 commit 24d5b72Copy full SHA for 24d5b72
src/RollbarServiceProvider.php
@@ -1,6 +1,7 @@
1
<?php namespace Jenssegers\Rollbar;
2
3
use Illuminate\Support\ServiceProvider;
4
+use InvalidArgumentException;
5
use Rollbar;
6
use RollbarNotifier;
7
@@ -49,6 +50,10 @@ public function register()
49
50
51
$config['access_token'] = getenv('ROLLBAR_TOKEN') ?: $app['config']->get('services.rollbar.access_token');
52
53
+ if (empty($config['access_token'])) {
54
+ throw new InvalidArgumentException('Rollbar access token not configured');
55
+ }
56
+
57
Rollbar::$instance = $rollbar = new RollbarNotifier($config);
58
59
return $rollbar;
0 commit comments