@@ -33,7 +33,7 @@ |
||
| 33 | 33 | |
| 34 | 34 | $container->extend( |
| 35 | 35 | EventServiceProvider::CONTAINER_KEY_DEFAULT_EVENT_ERROR_HANDLERS, |
| 36 | - static function (array $defaultEventErrorHandlers, Container $container) { |
|
| 36 | + static function(array $defaultEventErrorHandlers, Container $container) { |
|
| 37 | 37 | $logger = $container->offsetGet(LogServiceProvider::CONTAINER_KEY_LOGGER); |
| 38 | 38 | |
| 39 | 39 | $defaultEventErrorHandlers[] = new LogEventErrorHandler($logger); |
@@ -30,7 +30,7 @@ |
||
| 30 | 30 | { |
| 31 | 31 | $self = $this; |
| 32 | 32 | |
| 33 | - $container->offsetSet('queue_client', static function (Container $container) use ($self) { |
|
| 33 | + $container->offsetSet('queue_client', static function(Container $container) use ($self) { |
|
| 34 | 34 | return new QueueClient( |
| 35 | 35 | $self->createConnection($container), |
| 36 | 36 | $self->createAmqpMessageFactory(), |
@@ -45,7 +45,7 @@ |
||
| 45 | 45 | while (true) { |
| 46 | 46 | foreach ($listeners as $eventName => $listenersPerEvent) { |
| 47 | 47 | foreach ($listenersPerEvent as $listenerIdentifier => $listener) { |
| 48 | - $this->eventQueueConsumer->dequeueAsProcess((string)$eventName, $listenerIdentifier); |
|
| 48 | + $this->eventQueueConsumer->dequeueAsProcess((string) $eventName, $listenerIdentifier); |
|
| 49 | 49 | usleep(static::DELAY_INTERVAL); |
| 50 | 50 | } |
| 51 | 51 | } |
@@ -144,7 +144,7 @@ discard block |
||
| 144 | 144 | */ |
| 145 | 145 | protected function registerEventFactory(Container $container): EventServiceProvider |
| 146 | 146 | { |
| 147 | - $container->offsetSet(static::CONTAINER_KEY_EVENT_FACTORY, static function () { |
|
| 147 | + $container->offsetSet(static::CONTAINER_KEY_EVENT_FACTORY, static function() { |
|
| 148 | 148 | return new EventFactory(); |
| 149 | 149 | }); |
| 150 | 150 | |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | |
| 163 | 163 | $container->offsetSet( |
| 164 | 164 | static::CONTAINER_KEY_EVENT_DISPATCHER, |
| 165 | - static function (Container $container) use ($self) { |
|
| 165 | + static function(Container $container) use ($self) { |
|
| 166 | 166 | return new EventDispatcher( |
| 167 | 167 | new EventListenerProvider(), |
| 168 | 168 | $self->createEventQueueProducer($container) |
@@ -182,7 +182,7 @@ discard block |
||
| 182 | 182 | { |
| 183 | 183 | $self = $this; |
| 184 | 184 | |
| 185 | - $container->extend('commands', static function (array $commands, Container $container) use ($self) { |
|
| 185 | + $container->extend('commands', static function(array $commands, Container $container) use ($self) { |
|
| 186 | 186 | $commands[] = new EventQueueConsumeCommand( |
| 187 | 187 | $container->offsetGet('event_dispatcher')->getEventListenerProvider(), |
| 188 | 188 | $self->createEventQueueConsumer($container), |
@@ -207,7 +207,7 @@ discard block |
||
| 207 | 207 | */ |
| 208 | 208 | protected function registerDefaultEventErrorHandlers(Container $container): EventServiceProvider |
| 209 | 209 | { |
| 210 | - $container->offsetSet(static::CONTAINER_KEY_DEFAULT_EVENT_ERROR_HANDLERS, static function () { |
|
| 210 | + $container->offsetSet(static::CONTAINER_KEY_DEFAULT_EVENT_ERROR_HANDLERS, static function() { |
|
| 211 | 211 | return []; |
| 212 | 212 | }); |
| 213 | 213 | |
@@ -34,7 +34,7 @@ |
||
| 34 | 34 | { |
| 35 | 35 | $self = $this; |
| 36 | 36 | |
| 37 | - $container->offsetSet(static::CONTAINER_KEY_LOGGER, static function (Container $container) use ($self) { |
|
| 37 | + $container->offsetSet(static::CONTAINER_KEY_LOGGER, static function(Container $container) use ($self) { |
|
| 38 | 38 | $logger = new Logger('jellyfish'); |
| 39 | 39 | |
| 40 | 40 | $logger->pushHandler($self->createStreamHandler($container)); |
@@ -18,7 +18,7 @@ |
||
| 18 | 18 | { |
| 19 | 19 | $self = $this; |
| 20 | 20 | |
| 21 | - $pimple->offsetSet('config', static function (Container $container) use ($self) { |
|
| 21 | + $pimple->offsetSet('config', static function(Container $container) use ($self) { |
|
| 22 | 22 | return $self->createConfig($container); |
| 23 | 23 | }); |
| 24 | 24 | } |