@@ -56,7 +56,7 @@ |
||
56 | 56 | */ |
57 | 57 | private function turn($key, callable $closure = null) |
58 | 58 | { |
59 | - $key = 'heyman_ignore_'.$key; |
|
59 | + $key = 'heyman_ignore_' . $key; |
|
60 | 60 | |
61 | 61 | $current = config($key); |
62 | 62 | $this->changeMode($key); |
@@ -40,7 +40,7 @@ |
||
40 | 40 | $method = ltrim($method, 'about'); |
41 | 41 | |
42 | 42 | if (in_array($method, ['Route', 'Action', 'Url'])) { |
43 | - $args = resolve(RouteNormalizer::class)->{'normalize'.$method}($args); |
|
43 | + $args = resolve(RouteNormalizer::class)->{'normalize' . $method}($args); |
|
44 | 44 | return resolve(RouterEventManager::class)->forgetAbout($args); |
45 | 45 | } |
46 | 46 |
@@ -6,8 +6,8 @@ |
||
6 | 6 | { |
7 | 7 | public function wrapForIgnorance(callable $callback, $key): \Closure |
8 | 8 | { |
9 | - return function (...$args) use ($callback, $key) { |
|
10 | - if (!config('heyman_ignore_'.$key, false)) { |
|
9 | + return function(...$args) use ($callback, $key) { |
|
10 | + if (!config('heyman_ignore_' . $key, false)) { |
|
11 | 11 | $callback(...$args); |
12 | 12 | } |
13 | 13 | }; |
@@ -10,15 +10,15 @@ |
||
10 | 10 | return; |
11 | 11 | } |
12 | 12 | |
13 | - app()->singleton('heyman.debugger', function () { |
|
13 | + app()->singleton('heyman.debugger', function() { |
|
14 | 14 | return new \DebugBar\DataCollector\MessagesCollector('HeyMan'); |
15 | 15 | }); |
16 | 16 | |
17 | 17 | app()->make('debugbar')->addCollector(app('heyman.debugger')); |
18 | 18 | |
19 | - \Event::listen('heyman_reaction_is_happening', function (...$debug) { |
|
20 | - resolve('heyman.debugger')->addMessage('HeyMan Rule Matched in file: '.$debug[0]); |
|
21 | - resolve('heyman.debugger')->addMessage('on line: '.$debug[1]); |
|
19 | + \Event::listen('heyman_reaction_is_happening', function(...$debug) { |
|
20 | + resolve('heyman.debugger')->addMessage('HeyMan Rule Matched in file: ' . $debug[0]); |
|
21 | + resolve('heyman.debugger')->addMessage('on line: ' . $debug[1]); |
|
22 | 22 | resolve('heyman.debugger')->addMessage($debug[2]); |
23 | 23 | }); |
24 | 24 | } |
@@ -6,7 +6,7 @@ |
||
6 | 6 | { |
7 | 7 | public function sessionShouldHave($key) |
8 | 8 | { |
9 | - return function () use ($key) { |
|
9 | + return function() use ($key) { |
|
10 | 10 | return session()->has($key); |
11 | 11 | }; |
12 | 12 | } |
@@ -6,14 +6,14 @@ |
||
6 | 6 | { |
7 | 7 | public function youShouldBeGuest($guard = null) |
8 | 8 | { |
9 | - return function () use ($guard) { |
|
9 | + return function() use ($guard) { |
|
10 | 10 | return auth($guard)->guest(); |
11 | 11 | }; |
12 | 12 | } |
13 | 13 | |
14 | 14 | public function youShouldBeLoggedIn($guard = null) |
15 | 15 | { |
16 | - return function () use ($guard) { |
|
16 | + return function() use ($guard) { |
|
17 | 17 | return auth($guard)->check(); |
18 | 18 | }; |
19 | 19 | } |
@@ -11,15 +11,15 @@ |
||
11 | 11 | |
12 | 12 | public function thisMethodShouldAllow($callback, array $parameters = []) |
13 | 13 | { |
14 | - return function (...$payload) use ($callback, $parameters) { |
|
15 | - return (bool) app()->call($callback, array_merge($parameters, ...$payload)); |
|
14 | + return function(...$payload) use ($callback, $parameters) { |
|
15 | + return (bool)app()->call($callback, array_merge($parameters, ...$payload)); |
|
16 | 16 | }; |
17 | 17 | } |
18 | 18 | |
19 | 19 | public function thisValueShouldAllow($value) |
20 | 20 | { |
21 | - return function () use ($value) { |
|
22 | - return (bool) $value; |
|
21 | + return function() use ($value) { |
|
22 | + return (bool)$value; |
|
23 | 23 | }; |
24 | 24 | } |
25 | 25 | } |
@@ -10,7 +10,7 @@ |
||
10 | 10 | { |
11 | 11 | $gate = $this->defineNewGate($gate); |
12 | 12 | |
13 | - return function (...$payload) use ($gate, $parameters) { |
|
13 | + return function(...$payload) use ($gate, $parameters) { |
|
14 | 14 | return GateFacade::allows($gate, (array_merge($parameters, ...$payload))); |
15 | 15 | }; |
16 | 16 | } |
@@ -29,6 +29,6 @@ |
||
29 | 29 | |
30 | 30 | public function checkPoint($pointName) |
31 | 31 | { |
32 | - event('heyman_checkpoint_'.$pointName); |
|
32 | + event('heyman_checkpoint_' . $pointName); |
|
33 | 33 | } |
34 | 34 | } |