Passed
Push — master ( 162a39...7b742a )
by Malte
02:35
created
src/IMAP/Query/Query.php 1 patch
Braces   +11 added lines, -5 removed lines patch added patch discarded remove patch
@@ -64,7 +64,9 @@  discard block
 block discarded – undo
64 64
     public function __construct(Client $client, $charset = 'UTF-8') {
65 65
         $this->setClient($client);
66 66
 
67
-        if(config('imap.options.fetch') === FT_PEEK) $this->leaveUnread();
67
+        if(config('imap.options.fetch') === FT_PEEK) {
68
+            $this->leaveUnread();
69
+        }
68 70
 
69 71
         $this->charset = $charset;
70 72
         $this->query = collect();
@@ -100,7 +102,9 @@  discard block
 block discarded – undo
100 102
      * @throws MessageSearchValidationException
101 103
      */
102 104
     protected function parse_date($date) {
103
-        if($date instanceof \Carbon\Carbon) return $date;
105
+        if($date instanceof \Carbon\Carbon) {
106
+            return $date;
107
+        }
104 108
 
105 109
         try {
106 110
             $date = Carbon::parse($date);
@@ -151,7 +155,7 @@  discard block
 block discarded – undo
151 155
              */
152 156
             if($this->getCharset() === null){
153 157
                 $available_messages = imap_search($this->getClient()->getConnection(), $this->getRawQuery(), SE_UID);
154
-            }else{
158
+            } else{
155 159
                 $available_messages = imap_search($this->getClient()->getConnection(), $this->getRawQuery(), SE_UID, $this->getCharset());
156 160
             }
157 161
 
@@ -203,7 +207,7 @@  discard block
 block discarded – undo
203 207
             } else {
204 208
                 if($statement[1] === null){
205 209
                     $query .= $statement[0];
206
-                }else{
210
+                } else{
207 211
                     $query .= $statement[0].' "'.$statement[1].'"';
208 212
                 }
209 213
             }
@@ -232,7 +236,9 @@  discard block
 block discarded – undo
232 236
      * @return $this
233 237
      */
234 238
     public function limit($limit, $page = 1) {
235
-        if($page >= 1) $this->page = $page;
239
+        if($page >= 1) {
240
+            $this->page = $page;
241
+        }
236 242
         $this->limit = $limit;
237 243
 
238 244
         return $this;
Please login to merge, or discard this patch.