Completed
Pull Request — master (#48)
by
unknown
02:23 queued 02:23
created
src/DataLayer.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -261,9 +261,9 @@  discard block
 block discarded – undo
261 261
      */
262 262
     protected function required(): bool
263 263
     {
264
-        $data = (array)$this->data();
264
+        $data = (array) $this->data();
265 265
         foreach ($this->required as $field) {
266
-            if (empty($data[$field])) {
266
+            if (empty($data[ $field ])) {
267 267
                 return false;
268 268
             }
269 269
         }
@@ -275,8 +275,8 @@  discard block
 block discarded – undo
275 275
      */
276 276
     protected function safe(): ?array
277 277
     {
278
-        $safe = (array)$this->data;
279
-        unset($safe[$this->primary]);
278
+        $safe = (array) $this->data;
279
+        unset($safe[ $this->primary ]);
280 280
 
281 281
         return $safe;
282 282
     }
Please login to merge, or discard this patch.
example/Models/User.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@
 block discarded – undo
15 15
      */
16 16
     public function __construct()
17 17
     {
18
-        parent::__construct("users", ["first_name", "last_name"], "id", true, DATA_LAYER_CONFIG_2);
18
+        parent::__construct("users", [ "first_name", "last_name" ], "id", true, DATA_LAYER_CONFIG_2);
19 19
     }
20 20
 
21 21
     public function fullName()
Please login to merge, or discard this patch.
src/Connect.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -25,10 +25,10 @@
 block discarded – undo
25 25
         if (empty(self::$instance)) {
26 26
             try {
27 27
                 self::$instance = new PDO(
28
-                    $bd["driver"] . ":host=" . $bd["host"] . ";dbname=" . $bd["dbname"] . ";port=" . $bd["port"],
29
-                    $bd["username"],
30
-                    $bd["passwd"],
31
-                    $bd["options"]
28
+                    $bd[ "driver" ] . ":host=" . $bd[ "host" ] . ";dbname=" . $bd[ "dbname" ] . ";port=" . $bd[ "port" ],
29
+                    $bd[ "username" ],
30
+                    $bd[ "passwd" ],
31
+                    $bd[ "options" ]
32 32
                 );
33 33
             } catch (PDOException $exception) {
34 34
                 self::$error = $exception;
Please login to merge, or discard this patch.