Completed
Pull Request — 1.0 (#5)
by Benoit
02:05
created
src/Objects/Exchange.php 1 patch
Doc Comments   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -86,7 +86,6 @@  discard block
 block discarded – undo
86 86
     /**
87 87
      * Set the to (Binding).
88 88
      *
89
-     * @param Client $to
90 89
      * @param string $name
91 90
      * @param string $type direct, topic, headers or fanout
92 91
      */
@@ -292,6 +291,9 @@  discard block
 block discarded – undo
292 291
         }
293 292
     }
294 293
 
294
+    /**
295
+     * @param string $routingKey
296
+     */
295 297
     public function publish(Message $message, $routingKey, $mandatory = false,
296 298
                             $immediate = false,
297 299
                             $ticket = null)
Please login to merge, or discard this patch.
src/Objects/Queue.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -539,7 +539,7 @@
 block discarded – undo
539 539
                                     $consumer->isNoAck(),
540 540
                                     $consumer->isExclusive(),
541 541
                                     $consumer->isNoWait(),
542
-                                    function (AMQPMessage $msg) use ($consumer) {
542
+                                    function(AMQPMessage $msg) use ($consumer) {
543 543
                                         $consumer->callback($msg);
544 544
                                     },
545 545
                                     $consumer->getTicket(),
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -133,7 +133,6 @@  discard block
 block discarded – undo
133 133
     /**
134 134
      * Set the source (Binding).
135 135
      *
136
-     * @param Binding             $source
137 136
      * @param string              $name
138 137
      * @param ConsumerInterface[] $consumers
139 138
      */
@@ -324,7 +323,7 @@  discard block
 block discarded – undo
324 323
     /**
325 324
      * Get RabbitMq specific parameter : dead letter queue.
326 325
      *
327
-     * @return Queue
326
+     * @return Exchange
328 327
      */
329 328
     public function getDeadLetterExchanger()
330 329
     {
Please login to merge, or discard this patch.
src/Client.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -196,7 +196,7 @@
 block discarded – undo
196 196
      */
197 197
     public function getQueues()
198 198
     {
199
-        return array_filter($this->rabbitMqObjects, function (RabbitMqObjectInterface $object) {
199
+        return array_filter($this->rabbitMqObjects, function(RabbitMqObjectInterface $object) {
200 200
             return $object instanceof QueueInterface;
201 201
         });
202 202
     }
Please login to merge, or discard this patch.
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -178,11 +178,11 @@
 block discarded – undo
178 178
                 $this->connection = new AMQPStreamConnection($this->host, $this->port, $this->user, $this->password);
179 179
             } catch (\ErrorException $e) {
180 180
                 /**
181
-                * We are trying to catch the exception when the connection if refused
182
-                **/
183
-              if (preg_match("/.*unable to connect.*Connection refused.*/", $e->__toString())) {
184
-                  throw new ConnectionException("Cannot create the connection", 404, $e);
185
-              }
181
+                 * We are trying to catch the exception when the connection if refused
182
+                 **/
183
+                if (preg_match("/.*unable to connect.*Connection refused.*/", $e->__toString())) {
184
+                    throw new ConnectionException("Cannot create the connection", 404, $e);
185
+                }
186 186
                 throw $e;
187 187
             }
188 188
             $this->channel = $this->connection->channel();
Please login to merge, or discard this patch.
tests/ClientTest.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@
 block discarded – undo
38 38
         global $rabbitmq_password;
39 39
 
40 40
         if (!$port) {
41
-          $port = $rabbitmq_port;
41
+            $port = $rabbitmq_port;
42 42
         }
43 43
 
44 44
 
Please login to merge, or discard this patch.