Passed
Push — main ( e88b44...75c293 )
by William
10:29
created
src/QueryHelpers.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -529,7 +529,9 @@
 block discarded – undo
529 529
 
530 530
         $queryString = "";
531 531
 
532
-        if (empty($queryParams["filters"])) return "";
532
+        if (empty($queryParams["filters"])) {
533
+            return "";
534
+        }
533 535
 
534 536
         foreach ($queryParams["filters"] as $key => $filtro) {
535 537
             if ($key === 0) {
Please login to merge, or discard this patch.
example/teste.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@
 block discarded – undo
64 64
 
65 65
 
66 66
 $db = (new Create())->from("users")->create([
67
-    'email' => generateRandomString()."@teste.com",
67
+    'email' => generateRandomString() . "@teste.com",
68 68
     'last_name' => generateRandomString()
69 69
 ])->exec();
70 70
 
Please login to merge, or discard this patch.
example/example.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
  */
145 145
 $dbSub = (new Query())->from('users as u')->where("2 = ?", [2])->limit(10);
146 146
 
147
-$data = (new Query())->fromSubQuery(function (Query $query) {
147
+$data = (new Query())->fromSubQuery(function(Query $query) {
148 148
     return $query->from("users")->selectRaw('id,first_name')->where("1 = ?", [1])->limit(10);
149 149
 }, 'sub')
150 150
     ->where('4 = ?', [4])
@@ -231,7 +231,7 @@  discard block
 block discarded – undo
231 231
         "u.id",
232 232
         "count(ao.id) as qtd"
233 233
     ])
234
-    ->join("app_orders as ao","ao.user_id = u.id")
234
+    ->join("app_orders as ao", "ao.user_id = u.id")
235 235
     ->groupBy("u.id")
236 236
     ->having("count(ao.id) > ?", [1])
237 237
     ->get();
Please login to merge, or discard this patch.