Completed
Pull Request — master (#46)
by Nicolas
05:29
created
src/Messages/Bodies/Json.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
 
44 44
     public function changeContent($content): void
45 45
     {
46
-        if(! is_array($content))
46
+        if( ! is_array($content))
47 47
         {
48 48
             $content = array($content);
49 49
         }
Please login to merge, or discard this patch.
src/Clients/Pecl.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
 
46 46
     private function ensureIsConnected(): void
47 47
     {
48
-        if(! $this->channel instanceof \AMQPChannel)
48
+        if( ! $this->channel instanceof \AMQPChannel)
49 49
         {
50 50
             $configuration = new PrefixedConfiguration($this->configuration, 'amqp/broker');
51 51
 
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
 
145 145
         $ex = new \AMQPExchange($this->channel);
146 146
 
147
-        if(!empty($exchangeName))
147
+        if( ! empty($exchangeName))
148 148
         {
149 149
             $ex->setName($exchangeName);
150 150
             $ex->setType($type);
Please login to merge, or discard this patch.
src/Messages/Message.php 2 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -175,6 +175,9 @@
 block discarded – undo
175 175
         return $this->headers;
176 176
     }
177 177
 
178
+    /**
179
+     * @param string $value
180
+     */
178 181
     public function setAttribute(string $attributeName, $value): WritableMessage
179 182
     {
180 183
         if($attributeName !== 'headers')
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -212,7 +212,8 @@
 block discarded – undo
212 212
 
213 213
     public function __toString(): string
214 214
     {
215
-        try {
215
+        try
216
+        {
216 217
             return (string) Json::encode([
217 218
                 'routing_key' => $this->getRoutingKey(),
218 219
                 'body' => (string) $this->body,
Please login to merge, or discard this patch.