Completed
Push — master ( 689bbd...10426d )
by Dan
01:37
created
src/Plugin/PluginManager.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -84,6 +84,9 @@  discard block
 block discarded – undo
84 84
         $this->updatePrefixes($authedUser->getUsername());
85 85
     }
86 86
 
87
+    /**
88
+     * @param string $text
89
+     */
87 90
     public function matchesPrefix($prefix, $text) : array
88 91
     {
89 92
         if ($prefix === self::NO_PREFIX) {
@@ -195,6 +198,9 @@  discard block
 block discarded – undo
195 198
         return $this->authedUser;
196 199
     }
197 200
 
201
+    /**
202
+     * @param string $authedUsername
203
+     */
198 204
     protected function updatePrefixes($authedUsername)
199 205
     {
200 206
         $updatedPriorityMap = [];
Please login to merge, or discard this patch.
src/Message/MessageFactory.php 1 patch
Doc Comments   +9 added lines patch added patch discarded remove patch
@@ -130,6 +130,9 @@  discard block
 block discarded – undo
130 130
         return $readable ? $readable : $entity;
131 131
     }
132 132
 
133
+    /**
134
+     * @param string $readable
135
+     */
133 136
     public function formatUser(string $entity, $readable = null) : string
134 137
     {
135 138
         if ($readable) {
@@ -144,6 +147,9 @@  discard block
 block discarded – undo
144 147
         return $entity;
145 148
     }
146 149
 
150
+    /**
151
+     * @param string $readable
152
+     */
147 153
     public function formatChannel(string $entity, $readable = null) : string
148 154
     {
149 155
         if ($readable) {
@@ -158,6 +164,9 @@  discard block
 block discarded – undo
158 164
         return $entity;
159 165
     }
160 166
 
167
+    /**
168
+     * @param string $param
169
+     */
161 170
     protected function isMessageChanged(array $data, $param = null): bool
162 171
     {
163 172
         return isset($data['subtype'])
Please login to merge, or discard this patch.
src/Yabot.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -93,12 +93,12 @@  discard block
 block discarded – undo
93 93
 
94 94
         Timer\timeout($slack->connect(), 30, $this->getLoop())
95 95
             ->then([$this, 'connected'])
96
-            ->otherwise(function (Timer\TimeoutException $error) {
96
+            ->otherwise(function(Timer\TimeoutException $error) {
97 97
                 $this->getLog()->error($error->getMessage());
98 98
                 $this->getLog()->error('Connection failed, shutting down.');
99 99
                 $this->shutDown();
100 100
             })
101
-            ->otherwise(function ($error) {
101
+            ->otherwise(function($error) {
102 102
                 $this->getLog()->error('Connection failed, shutting down.');
103 103
                 $this->shutDown();
104 104
             });
@@ -125,11 +125,11 @@  discard block
 block discarded – undo
125 125
         }
126 126
 
127 127
         $this->getSlack()->reconnect()->then(
128
-            function () {
128
+            function() {
129 129
                 $this->getLog()->info('Reconnected');
130 130
                 $this->monitor = $this->startConnectionMonitor();
131 131
             },
132
-            function () {
132
+            function() {
133 133
                 $this->getLog()->error('Reconnect failed, shutting down.');
134 134
                 $this->shutDown();
135 135
             }
@@ -218,7 +218,7 @@  discard block
 block discarded – undo
218 218
     protected function logMessage($data)
219 219
     {
220 220
         if ($this->messageLog !== null) {
221
-            file_put_contents($this->messageLog, json_encode($data) . "\n", FILE_APPEND);
221
+            file_put_contents($this->messageLog, json_encode($data)."\n", FILE_APPEND);
222 222
         }
223 223
     }
224 224
 
@@ -234,7 +234,7 @@  discard block
 block discarded – undo
234 234
 
235 235
             $this->ping();
236 236
 
237
-            return $this->loop->addPeriodicTimer($interval, function () {
237
+            return $this->loop->addPeriodicTimer($interval, function() {
238 238
                 $this->checkPong();
239 239
                 $this->ping();
240 240
             });
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
 
268 268
         $this->getSlack()->ping()
269 269
             ->then(
270
-                function (Payload $payload) {
270
+                function(Payload $payload) {
271 271
                     $this->getLog()->info($payload->toJson());
272 272
                     $this->pong = true;
273 273
                 }
Please login to merge, or discard this patch.