Completed
Push — master ( cbc691...72a5fc )
by Eric
02:18
created
src/Jarvis.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
      */
117 117
     public function analyze(Request $request = null) : Response
118 118
     {
119
-        $request = $request ?? $this->request;
119
+        $request = $request ? ? $this->request;
120 120
         $response = null;
121 121
 
122 122
         try {
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
         }
192 192
 
193 193
         if (isset($this->receivers[$eventName])) {
194
-            $event = $event ?? new SimpleEvent();
194
+            $event = $event ? ? new SimpleEvent();
195 195
             foreach ($this->buildEventReceivers($eventName) as $receiver) {
196 196
                 call_user_func_array($this->callback_resolver->resolve($receiver), [$event]);
197 197
 
@@ -253,7 +253,7 @@  discard block
 block discarded – undo
253 253
      */
254 254
     private function buildEventReceivers(string $eventName)
255 255
     {
256
-        return $this->computedReceivers[$eventName] = $this->computedReceivers[$eventName] ?? array_merge(
256
+        return $this->computedReceivers[$eventName] = $this->computedReceivers[$eventName] ? ? array_merge(
257 257
             $this->receivers[$eventName][self::RECEIVER_HIGH_PRIORITY],
258 258
             $this->receivers[$eventName][self::RECEIVER_NORMAL_PRIORITY],
259 259
             $this->receivers[$eventName][self::RECEIVER_LOW_PRIORITY]
Please login to merge, or discard this patch.
Doc Comments   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -113,8 +113,8 @@  discard block
 block discarded – undo
113 113
     }
114 114
 
115 115
     /**
116
-     * @param  Request|null $request
117
-     * @return Response
116
+     * @param  null|\Symfony\Component\HttpFoundation\Request $request
117
+     * @return \Symfony\Component\HttpFoundation\Response
118 118
      */
119 119
     public function analyze(Request $request = null) : Response
120 120
     {
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
 
159 159
     /**
160 160
      * @param  string  $eventName
161
-     * @param  mixed   $receiver
161
+     * @param  \Closure   $receiver
162 162
      * @param  integer $priority
163 163
      * @return self
164 164
      */
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
 
181 181
     /**
182 182
      * @param  string              $eventName
183
-     * @param  EventInterface|null $event
183
+     * @param  null|Skill\EventBroadcaster\EventInterface $event
184 184
      * @return self
185 185
      */
186 186
     public function broadcast(string $eventName, EventInterface $event = null) : Jarvis
@@ -207,7 +207,7 @@  discard block
 block discarded – undo
207 207
     }
208 208
 
209 209
     /**
210
-     * @param  ContainerProviderInterface $provider
210
+     * @param  Skill\DependencyInjection\ContainerProviderInterface $provider
211 211
      * @return self
212 212
      */
213 213
     public function hydrate(ContainerProviderInterface $provider) : Jarvis
Please login to merge, or discard this patch.
src/Skill/DependencyInjection/ContainerProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
             }
43 43
 
44 44
             $request = $classname::createFromGlobals();
45
-            $request->setSession($request->getSession() ?? new Session());
45
+            $request->setSession($request->getSession() ? ? new Session());
46 46
 
47 47
             return $request;
48 48
         };
Please login to merge, or discard this patch.
src/Skill/EventBroadcaster/AnalyzeEvent.php 1 patch
Doc Comments   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
     /**
18 18
      * Creates an instance of AnalyzeEvent.
19 19
      *
20
-     * @param Request $request
20
+     * @param \Symfony\Component\HttpFoundation\Request $request
21 21
      */
22 22
     public function __construct(Request $request)
23 23
     {
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     /**
28 28
      * @codeCoverageIgnore
29 29
      *
30
-     * @return Request
30
+     * @return \Symfony\Component\HttpFoundation\Request
31 31
      */
32 32
     public function request() : Request
33 33
     {
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     /**
38 38
      * @codeCoverageIgnore
39 39
      *
40
-     * @return Response|null
40
+     * @return \Symfony\Component\HttpFoundation\Response
41 41
      */
42 42
     public function response()
43 43
     {
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
     /**
48 48
      * @codeCoverageIgnore
49 49
      *
50
-     * @param  Response $response
50
+     * @param  \Symfony\Component\HttpFoundation\Response $response
51 51
      * @return self
52 52
      */
53 53
     public function setResponse(Response $response) : AnalyzeEvent
Please login to merge, or discard this patch.
src/Skill/EventBroadcaster/ResponseEvent.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
     /**
24 24
      * @codeCoverageIgnore
25 25
      *
26
-     * @return Request
26
+     * @return \Symfony\Component\HttpFoundation\Request
27 27
      */
28 28
     public function request() : Request
29 29
     {
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
     /**
34 34
      * @codeCoverageIgnore
35 35
      *
36
-     * @return Response
36
+     * @return \Symfony\Component\HttpFoundation\Response
37 37
      */
38 38
     public function response() : Response
39 39
     {
Please login to merge, or discard this patch.
src/Skill/Routing/Router.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
      */
35 35
     public function addRoute(Route $route) : Router
36 36
     {
37
-        $this->rawRoutes[$route->scope()] = $this->rawRoutes[$route->scope()] ?? [];
37
+        $this->rawRoutes[$route->scope()] = $this->rawRoutes[$route->scope()] ? ? [];
38 38
         $this->rawRoutes[$route->scope()][] = [$route->method(), $route->pattern(), $route->handler()];
39 39
         $this->compilationKey = null;
40 40
 
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
 
75 75
             $value = (string) $value;
76 76
             $pieces = explode(':', $matches[1]);
77
-            if (1 < count($pieces) && 1 !== preg_match('~' . $pieces[1] . '~', $value)) {
77
+            if (1 < count($pieces) && 1 !== preg_match('~'.$pieces[1].'~', $value)) {
78 78
                 continue;
79 79
             }
80 80
 
Please login to merge, or discard this patch.