Completed
Push — master ( 7bdb8b...9d6e0c )
by Iman
05:12
created
src/Hooks/RouteHooks.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -74,12 +74,12 @@  discard block
 block discarded – undo
74 74
      */
75 75
     public function whenYouCallAction(...$action)
76 76
     {
77
-        $addNamespace = function ($action) {
77
+        $addNamespace = function($action) {
78 78
             if ($action = ltrim($action, '\\')) {
79 79
                 return $action;
80 80
             }
81 81
 
82
-            return app()->getNamespace().'\\Http\\Controllers\\'.$action;
82
+            return app()->getNamespace() . '\\Http\\Controllers\\' . $action;
83 83
         };
84 84
 
85 85
         $action = array_map($addNamespace, $this->normalizeInput($action));
@@ -108,8 +108,8 @@  discard block
 block discarded – undo
108 108
      */
109 109
     private function authorizeURL($url, $verb): YouShouldHave
110 110
     {
111
-        $removeSlash = function ($url) use ($verb) {
112
-            return $verb.ltrim($url, '/');
111
+        $removeSlash = function($url) use ($verb) {
112
+            return $verb . ltrim($url, '/');
113 113
         };
114 114
 
115 115
         $url = array_map($removeSlash, $this->normalizeInput($url));
Please login to merge, or discard this patch.
src/WatchingStrategies/BasicEventManager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
      */
28 28
     public function startGuarding(callable $callback)
29 29
     {
30
-        $listener = function () use ($callback) {
30
+        $listener = function() use ($callback) {
31 31
             if (!config('heyman_ignore_event', false)) {
32 32
                 $callback();
33 33
             }
Please login to merge, or discard this patch.
src/YouShouldHave.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
     {
34 34
         $gate = $this->defineNewGate($gate);
35 35
 
36
-        $this->chain->predicate = function (...$payload) use ($gate, $parameters) {
36
+        $this->chain->predicate = function(...$payload) use ($gate, $parameters) {
37 37
             return Gate::allows($gate, (array_merge($parameters, ...$payload)));
38 38
         };
39 39
 
@@ -47,8 +47,8 @@  discard block
 block discarded – undo
47 47
 
48 48
     public function thisMethodShouldAllow($callback, array $parameters = []): Otherwise
49 49
     {
50
-        $this->chain->predicate = function (...$payload) use ($callback, $parameters) {
51
-            return (bool) app()->call($callback, array_merge($parameters, ...$payload));
50
+        $this->chain->predicate = function(...$payload) use ($callback, $parameters) {
51
+            return (bool)app()->call($callback, array_merge($parameters, ...$payload));
52 52
         };
53 53
 
54 54
         return app(Otherwise::class);
@@ -56,8 +56,8 @@  discard block
 block discarded – undo
56 56
 
57 57
     public function thisValueShouldAllow($value): Otherwise
58 58
     {
59
-        $this->chain->predicate = function () use ($value) {
60
-            return (bool) $value;
59
+        $this->chain->predicate = function() use ($value) {
60
+            return (bool)$value;
61 61
         };
62 62
 
63 63
         return app(Otherwise::class);
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
 
66 66
     public function youShouldBeGuest($guard = null): Otherwise
67 67
     {
68
-        $this->chain->predicate = function () use ($guard) {
68
+        $this->chain->predicate = function() use ($guard) {
69 69
             return auth($guard)->guest();
70 70
         };
71 71
 
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
 
75 75
     public function sessionShouldHave($key): Otherwise
76 76
     {
77
-        $this->chain->predicate = function () use ($key) {
77
+        $this->chain->predicate = function() use ($key) {
78 78
             return session()->has($key);
79 79
         };
80 80
 
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
 
84 84
     public function youShouldBeLoggedIn($guard = null): Otherwise
85 85
     {
86
-        $this->chain->predicate = function () use ($guard) {
86
+        $this->chain->predicate = function() use ($guard) {
87 87
             return auth($guard)->check();
88 88
         };
89 89
 
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
 
93 93
     public function youShouldAlways(): Actions
94 94
     {
95
-        $this->chain->predicate = function () {
95
+        $this->chain->predicate = function() {
96 96
             return false;
97 97
         };
98 98
 
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
      */
106 106
     public function yourRequestShouldBeValid($rules)
107 107
     {
108
-        $this->chain->predicate = function () use ($rules) {
108
+        $this->chain->predicate = function() use ($rules) {
109 109
             if (is_callable($rules)) {
110 110
                 $rules = $rules();
111 111
             }
Please login to merge, or discard this patch.