Completed
Push — master ( f58be8...855521 )
by Tilita
03:07
created
src/Command/SetupCommand.php 1 patch
Spacing   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
      *
30 30
      * @var string
31 31
      */
32
-    protected $description = 'Create all queues, exchanges and binds that are defined in entities AND referenced to' .
32
+    protected $description = 'Create all queues, exchanges and binds that are defined in entities AND referenced to'.
33 33
         ' either a publisher or a consumer';
34 34
 
35 35
     /**
@@ -64,8 +64,8 @@  discard block
 block discarded – undo
64 64
             $this->output->writeln(
65 65
                 sprintf(
66 66
                     "Deleting <info>%s</info> <fg=yellow>%s</>",
67
-                    (string)($entity instanceof QueueEntity) ? 'QUEUE' : 'EXCHANGE',
68
-                    (string)$entity->getAliasName()
67
+                    (string) ($entity instanceof QueueEntity) ? 'QUEUE' : 'EXCHANGE',
68
+                    (string) $entity->getAliasName()
69 69
                 )
70 70
             );
71 71
             $entity->delete();
@@ -75,10 +75,10 @@  discard block
 block discarded – undo
75 75
         $this->output->writeln(
76 76
             sprintf(
77 77
                 "Created <info>%s</info> <fg=yellow>%s</> for %s [<fg=yellow>%s</>]",
78
-                (string)($entity instanceof QueueEntity) ? 'QUEUE' : 'EXCHANGE',
79
-                (string)$entity->getAliasName(),
80
-                (string)$type,
81
-                (string)$resourceName
78
+                (string) ($entity instanceof QueueEntity) ? 'QUEUE' : 'EXCHANGE',
79
+                (string) $entity->getAliasName(),
80
+                (string) $type,
81
+                (string) $resourceName
82 82
             )
83 83
         );
84 84
     }
@@ -100,9 +100,9 @@  discard block
 block discarded – undo
100 100
                 $this->output->error(
101 101
                     sprintf(
102 102
                         "Could not create entity %s for publisher [%s], got:\n%s",
103
-                        (string)$entity->getAliasName(),
104
-                        (string)$publisherName,
105
-                        (string)$e->getMessage()
103
+                        (string) $entity->getAliasName(),
104
+                        (string) $publisherName,
105
+                        (string) $e->getMessage()
106 106
                     )
107 107
                 );
108 108
                 // @todo Fix type mismatch
@@ -119,9 +119,9 @@  discard block
 block discarded – undo
119 119
                 $this->output->error(
120 120
                     sprintf(
121 121
                         "Could not create entity %s for consumer [%s], got:\n%s",
122
-                        (string)$entity->getAliasName(),
123
-                        (string)$publisherName,
124
-                        (string)$e->getMessage()
122
+                        (string) $entity->getAliasName(),
123
+                        (string) $publisherName,
124
+                        (string) $e->getMessage()
125 125
                     )
126 126
                 );
127 127
                 // @todo Fix type mismatch
@@ -137,8 +137,8 @@  discard block
 block discarded – undo
137 137
                 $this->output->writeln(
138 138
                     sprintf(
139 139
                         "Created bind <info>%s</info> for publisher [<fg=yellow>%s</>]",
140
-                        (string)$entity->getAliasName(),
141
-                        (string)$publisherName
140
+                        (string) $entity->getAliasName(),
141
+                        (string) $publisherName
142 142
                     )
143 143
                 );
144 144
             } catch (\Exception $e) {
@@ -146,9 +146,9 @@  discard block
 block discarded – undo
146 146
                 $this->output->error(
147 147
                     sprintf(
148 148
                         "Could not bind entity %s for publisher [%s], got:\n%s",
149
-                        (string)$entity->getAliasName(),
150
-                        (string)$publisherName,
151
-                        (string)$e->getMessage()
149
+                        (string) $entity->getAliasName(),
150
+                        (string) $publisherName,
151
+                        (string) $e->getMessage()
152 152
                     )
153 153
                 );
154 154
             }
@@ -161,8 +161,8 @@  discard block
 block discarded – undo
161 161
                 $this->output->writeln(
162 162
                     sprintf(
163 163
                         "Bind entity <info>%s</info> for consumer [<fg=yellow>%s</>]",
164
-                        (string)$entity->getAliasName(),
165
-                        (string)$consumerAliasName
164
+                        (string) $entity->getAliasName(),
165
+                        (string) $consumerAliasName
166 166
                     )
167 167
                 );
168 168
             } catch (\Exception $e) {
@@ -170,13 +170,13 @@  discard block
 block discarded – undo
170 170
                 $this->output->error(
171 171
                     sprintf(
172 172
                         "Could not create bind %s for consumer [%s], got:\n%s",
173
-                        (string)$entity->getAliasName(),
174
-                        (string)$consumerAliasName,
175
-                        (string)$e->getMessage()
173
+                        (string) $entity->getAliasName(),
174
+                        (string) $consumerAliasName,
175
+                        (string) $e->getMessage()
176 176
                     )
177 177
                 );
178 178
             }
179 179
         }
180
-        return (int)$hasErrors;
180
+        return (int) $hasErrors;
181 181
     }
182 182
 }
Please login to merge, or discard this patch.
src/Processor/AbstractMessageProcessor.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -49,10 +49,10 @@  discard block
 block discarded – undo
49 49
             $this->logger->error(
50 50
                 sprintf(
51 51
                     "Could not process message, got %s from %s in %d for message: %s",
52
-                    get_class($e) . '-' . $e->getMessage(),
53
-                    (string)$e->getFile(),
54
-                    (int)$e->getLine(),
55
-                    (string)$message->getBody()
52
+                    get_class($e).'-'.$e->getMessage(),
53
+                    (string) $e->getFile(),
54
+                    (int) $e->getLine(),
55
+                    (string) $message->getBody()
56 56
                 )
57 57
             );
58 58
             $this->nack($message);
@@ -72,10 +72,10 @@  discard block
 block discarded – undo
72 72
             $this->logger->error(
73 73
                 sprintf(
74 74
                     "Could not process message, got %s from %s in %d for message: %s",
75
-                    get_class($e) . '-' . $e->getMessage(),
76
-                    (string)$e->getFile(),
77
-                    (int)$e->getLine(),
78
-                    (string)$message->getBody()
75
+                    get_class($e).'-'.$e->getMessage(),
76
+                    (string) $e->getFile(),
77
+                    (int) $e->getLine(),
78
+                    (string) $message->getBody()
79 79
                 )
80 80
             );
81 81
         }
Please login to merge, or discard this patch.
src/AMQPConnection.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
         'lazy'               => true,
29 29
 
30 30
         # More info about timeouts can be found on https://www.rabbitmq.com/networking.html
31
-        'read_write_timeout'   => 3,   // default timeout for writing/reading (in seconds)
31
+        'read_write_timeout'   => 3, // default timeout for writing/reading (in seconds)
32 32
         'connect_timeout'      => 3,
33 33
         'heartbeat'            => 0,
34 34
         'keep_alive'           => false
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
             throw new \InvalidArgumentException(
66 66
                 sprintf(
67 67
                     "Cannot create connection %s, received unknown arguments: %s!",
68
-                    (string)$aliasName,
68
+                    (string) $aliasName,
69 69
                     implode(', ', $diff)
70 70
                 )
71 71
             );
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
     {
88 88
         $this->aliasName = $aliasName;
89 89
         $this->connectionDetails = $connectionDetails;
90
-        if (isset($connectionDetails['lazy']) &&  $connectionDetails['lazy'] === false) {
90
+        if (isset($connectionDetails['lazy']) && $connectionDetails['lazy'] === false) {
91 91
             // dummy call
92 92
             $this->getConnection();
93 93
         }
Please login to merge, or discard this patch.