Completed
Push — master ( e23fd6...395432 )
by Iman
05:06
created
src/Reactions/ReactionFactory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
         $reaction = $this->makeReaction();
30 30
         $condition = $this->chain->condition;
31 31
 
32
-        return function (...$f) use ($condition, $reaction) {
32
+        return function(...$f) use ($condition, $reaction) {
33 33
             if (!$condition($f)) {
34 34
                 $reaction();
35 35
             }
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
         $responder = app(ResponderFactory::class)->make();
42 42
         $beforeResponse = $this->chain->beforeResponse();
43 43
 
44
-        return function () use ($beforeResponse, $responder) {
44
+        return function() use ($beforeResponse, $responder) {
45 45
             $beforeResponse();
46 46
             $responder();
47 47
         };
Please login to merge, or discard this patch.
src/Reactions/Validator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
     public function __destruct()
38 38
     {
39 39
         $data = $this->validationData;
40
-        $modifier = $this->modifier ?: function ($d) {
40
+        $modifier = $this->modifier ?: function($d) {
41 41
             return $d;
42 42
         };
43 43
         $this->chain->condition = app(ResponderFactory::class)->validatorCallback($modifier, ...$data);
Please login to merge, or discard this patch.
src/YouShouldHave.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
     {
35 35
         $gate = $this->defineNewGate($gate);
36 36
 
37
-        $this->chain->condition = function (...$payload) use ($gate, $parameters) {
37
+        $this->chain->condition = function(...$payload) use ($gate, $parameters) {
38 38
             return Gate::allows($gate, (array_merge($parameters, ...$payload)));
39 39
         };
40 40
 
@@ -48,8 +48,8 @@  discard block
 block discarded – undo
48 48
 
49 49
     public function thisMethodShouldAllow($callback, array $parameters = []): Otherwise
50 50
     {
51
-        $this->chain->condition = function (...$payload) use ($callback, $parameters) {
52
-            return (bool) app()->call($callback, array_merge($parameters, ...$payload));
51
+        $this->chain->condition = function(...$payload) use ($callback, $parameters) {
52
+            return (bool)app()->call($callback, array_merge($parameters, ...$payload));
53 53
         };
54 54
 
55 55
         return app(Otherwise::class);
@@ -57,8 +57,8 @@  discard block
 block discarded – undo
57 57
 
58 58
     public function thisValueShouldAllow($value): Otherwise
59 59
     {
60
-        $this->chain->condition = function () use ($value) {
61
-            return (bool) $value;
60
+        $this->chain->condition = function() use ($value) {
61
+            return (bool)$value;
62 62
         };
63 63
 
64 64
         return app(Otherwise::class);
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 
67 67
     public function youShouldBeGuest($guard = null): Otherwise
68 68
     {
69
-        $this->chain->condition = function () use ($guard) {
69
+        $this->chain->condition = function() use ($guard) {
70 70
             return auth($guard)->guest();
71 71
         };
72 72
 
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 
76 76
     public function sessionShouldHave($key): Otherwise
77 77
     {
78
-        $this->chain->condition = function () use ($key) {
78
+        $this->chain->condition = function() use ($key) {
79 79
             return session()->has($key);
80 80
         };
81 81
 
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 
85 85
     public function youShouldBeLoggedIn($guard = null): Otherwise
86 86
     {
87
-        $this->chain->condition = function () use ($guard) {
87
+        $this->chain->condition = function() use ($guard) {
88 88
             return auth($guard)->check();
89 89
         };
90 90
 
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
 
94 94
     public function youShouldAlways(): Reactions
95 95
     {
96
-        $this->chain->condition = function () {
96
+        $this->chain->condition = function() {
97 97
             return false;
98 98
         };
99 99
 
Please login to merge, or discard this patch.