Passed
Push — main ( cfd31f...988f4a )
by Roberto
02:16
created
src/Boson/DataTypes/PrimaryKey.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,9 @@
 block discarded – undo
8 8
   }
9 9
 
10 10
   public function validate($value){
11
-    if(is_null($value) && (!$this->null)) return false;
11
+    if(is_null($value) && (!$this->null)) {
12
+        return false;
13
+    }
12 14
     return true;
13 15
   }
14 16
 }
15 17
\ No newline at end of file
Please login to merge, or discard this patch.
src/Boson/DataTypes/NumberField.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,9 @@
 block discarded – undo
8 8
   }
9 9
 
10 10
   public function validate($value){
11
-    if(is_null($value) && (!$this->null)) return false;
11
+    if(is_null($value) && (!$this->null)) {
12
+        return false;
13
+    }
12 14
     return true;
13 15
   }
14 16
 }
15 17
\ No newline at end of file
Please login to merge, or discard this patch.
src/Boson/DataTypes/TextField.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,8 +15,12 @@
 block discarded – undo
15 15
 
16 16
   public function validate($value){
17 17
     return true;
18
-    if(is_null($value) && (!$this->nullable)) return false;
19
-    if(strlen($value) > $this->max_length) return false;
18
+    if(is_null($value) && (!$this->nullable)) {
19
+        return false;
20
+    }
21
+    if(strlen($value) > $this->max_length) {
22
+        return false;
23
+    }
20 24
     return true;
21 25
   }
22 26
 }
23 27
\ No newline at end of file
Please login to merge, or discard this patch.
src/Boson/DataTypes/CharField.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -12,8 +12,12 @@
 block discarded – undo
12 12
 
13 13
     public function validate($value)
14 14
     {
15
-        if(is_null($value) && (!$this->null)) return false;
16
-        if(strlen($value) > $this->max_length) return false;
15
+        if(is_null($value) && (!$this->null)) {
16
+            return false;
17
+        }
18
+        if(strlen($value) > $this->max_length) {
19
+            return false;
20
+        }
17 21
         return true;
18 22
     }
19 23
 }
Please login to merge, or discard this patch.
src/Boson/QuerySet.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -413,11 +413,13 @@
 block discarded – undo
413 413
      *  @return QuerySet
414 414
      */
415 415
 
416
-    public function do(): QuerySet
416
+    public function do {
417
+        (): QuerySet
417 418
     {
418 419
 
419 420
         // Build the query
420 421
         list($query, $values) = $this->buildQuery();
422
+    }
421 423
 
422 424
         // Connect to DB
423 425
         $db = Application::getDb();
Please login to merge, or discard this patch.
src/Core/Database.php 1 patch
Braces   +12 added lines, -4 removed lines patch added patch discarded remove patch
@@ -56,7 +56,9 @@  discard block
 block discarded – undo
56 56
       }
57 57
       if ($callback != null && is_callable($callback)) {
58 58
         $value = $callback($r);//call_user_func($callback, $r);
59
-        if ($value == 'break') break;
59
+        if ($value == 'break') {
60
+            break;
61
+        }
60 62
       } else {
61 63
         $result[] = $r;
62 64
       }
@@ -113,9 +115,15 @@  discard block
 block discarded – undo
113 115
   }
114 116
 
115 117
 	private function _gettype($var) {
116
-	    if (is_string($var)) return 's';
117
-	    if (is_float($var)) return 'd';
118
-	    if (is_int($var)) return 'i';
118
+	    if (is_string($var)) {
119
+	        return 's';
120
+	    }
121
+	    if (is_float($var)) {
122
+	        return 'd';
123
+	    }
124
+	    if (is_int($var)) {
125
+	        return 'i';
126
+	    }
119 127
 	    return 'b';
120 128
 	}
121 129
 
Please login to merge, or discard this patch.