@@ -47,17 +47,17 @@ discard block |
||
47 | 47 | |
48 | 48 | $this->registerReporters(); |
49 | 49 | |
50 | - $this->app->bind(LogHandler::class, function ($app) { |
|
50 | + $this->app->bind(LogHandler::class, function($app) { |
|
51 | 51 | return new LogHandler($app[Reporter::class]); |
52 | 52 | }); |
53 | 53 | |
54 | - $this->app->singleton('honeybadger.isLumen', function () { |
|
54 | + $this->app->singleton('honeybadger.isLumen', function() { |
|
55 | 55 | return preg_match('/lumen/i', $this->app->version()); |
56 | 56 | }); |
57 | 57 | |
58 | 58 | $this->app->when(HoneybadgerDeployCommand::class) |
59 | 59 | ->needs(Client::class) |
60 | - ->give(function () { |
|
60 | + ->give(function() { |
|
61 | 61 | return new Client([ |
62 | 62 | 'http_errors' => false, |
63 | 63 | ]); |
@@ -109,8 +109,8 @@ discard block |
||
109 | 109 | private function registerEventHooks() |
110 | 110 | { |
111 | 111 | /** @param string|array|null $environments */ |
112 | - Event::macro('thenPingHoneybadger', function (string $id, $environments = null) { |
|
113 | - return $this->then(function () use ($id, $environments) { |
|
112 | + Event::macro('thenPingHoneybadger', function(string $id, $environments = null) { |
|
113 | + return $this->then(function() use ($id, $environments) { |
|
114 | 114 | if ($environments === null || app()->environment($environments)) { |
115 | 115 | app(Reporter::class)->checkin($id); |
116 | 116 | } |
@@ -118,8 +118,8 @@ discard block |
||
118 | 118 | }); |
119 | 119 | |
120 | 120 | /** @param string|array|null $environments */ |
121 | - Event::macro('pingHoneybadgerOnSuccess', function (string $id, $environments = null) { |
|
122 | - return $this->onSuccess(function () use ($id, $environments) { |
|
121 | + Event::macro('pingHoneybadgerOnSuccess', function(string $id, $environments = null) { |
|
122 | + return $this->onSuccess(function() use ($id, $environments) { |
|
123 | 123 | if ($environments === null || app()->environment($environments)) { |
124 | 124 | app(Reporter::class)->checkin($id); |
125 | 125 | } |
@@ -131,7 +131,7 @@ discard block |
||
131 | 131 | { |
132 | 132 | // Views are not enabled on Lumen by default |
133 | 133 | if (app()->bound('blade.compiler')) { |
134 | - Blade::directive('honeybadgerError', function ($options) { |
|
134 | + Blade::directive('honeybadgerError', function($options) { |
|
135 | 135 | if ($options === '') { |
136 | 136 | $options = '[]'; |
137 | 137 | } |
@@ -141,7 +141,7 @@ discard block |
||
141 | 141 | return "<?php echo \$__env->make('honeybadger::informer', $options, $defaults)->render(); ?>"; |
142 | 142 | }); |
143 | 143 | |
144 | - Blade::directive('honeybadgerFeedback', function () { |
|
144 | + Blade::directive('honeybadgerFeedback', function() { |
|
145 | 145 | $action = rtrim(Honeybadger::API_URL, '/').'/v1/feedback'; |
146 | 146 | |
147 | 147 | return "<?php echo \$__env->make('honeybadger::feedback', ['action' => '$action'])->render(); ?>"; |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | |
177 | 177 | protected function registerReporters(): void |
178 | 178 | { |
179 | - $this->app->singleton(Reporter::class, function ($app) { |
|
179 | + $this->app->singleton(Reporter::class, function($app) { |
|
180 | 180 | return HoneybadgerLaravel::make($app['config']['honeybadger']); |
181 | 181 | }); |
182 | 182 | |
@@ -186,9 +186,9 @@ discard block |
||
186 | 186 | // In some cases (like the test command), we definitely want to throw any errors |
187 | 187 | // Laravel's contextual binding doesn't support method injection, |
188 | 188 | // so the handle() method will have to request this client specifically. |
189 | - $this->app->singleton('honeybadger.loud', function ($app) { |
|
189 | + $this->app->singleton('honeybadger.loud', function($app) { |
|
190 | 190 | $config = $app['config']['honeybadger']; |
191 | - $config['service_exception_handler'] = function (ServiceException $e) { |
|
191 | + $config['service_exception_handler'] = function(ServiceException $e) { |
|
192 | 192 | throw $e; |
193 | 193 | }; |
194 | 194 |