Passed
Push — develop ( 353a13...172fe3 )
by nguereza
05:31 queued 02:53
created
src/DispatcherInterface.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,8 +46,7 @@
 block discarded – undo
46 46
 
47 47
 namespace Platine\Event;
48 48
 
49
-interface DispatcherInterface
50
-{
49
+interface DispatcherInterface {
51 50
 
52 51
     /**
53 52
      * The low priority
Please login to merge, or discard this patch.
src/Event.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -47,8 +47,7 @@  discard block
 block discarded – undo
47 47
 
48 48
 namespace Platine\Event;
49 49
 
50
-class Event implements EventInterface
51
-{
50
+class Event implements EventInterface {
52 51
 
53 52
     /**
54 53
      * The event name
@@ -73,8 +72,7 @@  discard block
 block discarded – undo
73 72
      * @param string $name       the event name
74 73
      * @param array  $arguments the event data
75 74
      */
76
-    public function __construct(string $name, array $arguments = [])
77
-    {
75
+    public function __construct(string $name, array $arguments = []) {
78 76
         $this->name = $name;
79 77
         $this->arguments = $arguments;
80 78
     }
@@ -127,8 +125,7 @@  discard block
 block discarded – undo
127 125
      * @param string $key
128 126
      * @return mixed
129 127
      */
130
-    public function getArgument(string $key)
131
-    {
128
+    public function getArgument(string $key) {
132 129
         return array_key_exists($key, $this->arguments) ? $this->arguments[$key] : null;
133 130
     }
134 131
 
Please login to merge, or discard this patch.
src/ListenerInterface.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,8 +46,7 @@
 block discarded – undo
46 46
 
47 47
 namespace Platine\Event;
48 48
 
49
-interface ListenerInterface
50
-{
49
+interface ListenerInterface {
51 50
 
52 51
     /**
53 52
      * Handle event
Please login to merge, or discard this patch.
src/EventInterface.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,8 +46,7 @@
 block discarded – undo
46 46
 
47 47
 namespace Platine\Event;
48 48
 
49
-interface EventInterface
50
-{
49
+interface EventInterface {
51 50
 
52 51
     /**
53 52
      * Get the  event name
Please login to merge, or discard this patch.
src/ListenerPriorityQueue.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -46,8 +46,7 @@  discard block
 block discarded – undo
46 46
 
47 47
 namespace Platine\Event;
48 48
 
49
-class ListenerPriorityQueue implements \IteratorAggregate
50
-{
49
+class ListenerPriorityQueue implements \IteratorAggregate {
51 50
 
52 51
     /**
53 52
      * The storage
@@ -66,8 +65,7 @@  discard block
 block discarded – undo
66 65
      * @param \SplObjectStorage $storage       the event name
67 66
      * @param \SplPriorityQueue  $queue the priority queue
68 67
      */
69
-    public function __construct(\SplObjectStorage $storage = null, \SplPriorityQueue $queue = null)
70
-    {
68
+    public function __construct(\SplObjectStorage $storage = null, \SplPriorityQueue $queue = null) {
71 69
         $this->storage = $storage ? $storage : new \SplObjectStorage();
72 70
         $this->queue = $queue ? $queue : new \SplPriorityQueue();
73 71
     }
Please login to merge, or discard this patch.
src/CallableListener.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -46,8 +46,7 @@  discard block
 block discarded – undo
46 46
 
47 47
 namespace Platine\Event;
48 48
 
49
-class CallableListener implements ListenerInterface
50
-{
49
+class CallableListener implements ListenerInterface {
51 50
 
52 51
     /**
53 52
      * The callable
@@ -65,8 +64,7 @@  discard block
 block discarded – undo
65 64
      * Create new instance
66 65
      * @param  callable $callable
67 66
      */
68
-    public function __construct(callable $callable)
69
-    {
67
+    public function __construct(callable $callable) {
70 68
         $this->callable = $callable;
71 69
         static::$listeners[] = $this;
72 70
     }
@@ -96,8 +94,7 @@  discard block
 block discarded – undo
96 94
      * @param  callable $callable the callable
97 95
      * @return CallableListener|false
98 96
      */
99
-    public static function getListener(callable $callable)
100
-    {
97
+    public static function getListener(callable $callable) {
101 98
         foreach (static::$listeners as $listener) {
102 99
             if ($listener->getCallable() == $callable) {
103 100
                 return $listener;
@@ -120,8 +117,7 @@  discard block
 block discarded – undo
120 117
      *
121 118
      * @return void
122 119
      */
123
-    public function handle(EventInterface $event)
124
-    {
120
+    public function handle(EventInterface $event) {
125 121
         ($this->callable)($event);
126 122
     }
127 123
 }
Please login to merge, or discard this patch.
src/SubscriberInterface.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,8 +46,7 @@
 block discarded – undo
46 46
 
47 47
 namespace Platine\Event;
48 48
 
49
-interface SubscriberInterface
50
-{
49
+interface SubscriberInterface {
51 50
 
52 51
     /**
53 52
      * Return the array of event to subscribe in form of
Please login to merge, or discard this patch.
src/Dispatcher.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -48,8 +48,7 @@
 block discarded – undo
48 48
 
49 49
 use Platine\Event\Exception\DispatcherException;
50 50
 
51
-class Dispatcher implements DispatcherInterface
52
-{
51
+class Dispatcher implements DispatcherInterface {
53 52
 
54 53
     /**
55 54
      * The list of listener
Please login to merge, or discard this patch.
src/Exception/DispatcherException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -32,7 +32,6 @@
 block discarded – undo
32 32
 
33 33
 namespace Platine\Event\Exception;
34 34
 
35
-class DispatcherException extends \Exception
36
-{
35
+class DispatcherException extends \Exception {
37 36
 
38 37
 }
Please login to merge, or discard this patch.