Passed
Push — master ( 125489...69b805 )
by Joao
04:53
created
src/Repository.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
 
70 70
     /**
71 71
      * @param array $id
72
-     * @return mixed|null
72
+     * @return boolean
73 73
      */
74 74
     public function delete($id)
75 75
     {
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
     }
83 83
 
84 84
     /**
85
-     * @param $query
85
+     * @param Query $query
86 86
      * @return bool
87 87
      */
88 88
     public function deleteByQuery($query)
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
                 $instance = $item->getEntity();
135 135
                 BinderObject::bindObject($row->toArray(), $instance);
136 136
 
137
-                foreach ((array)$item->getFieldMap() as $property => $fieldName) {
137
+                foreach ((array) $item->getFieldMap() as $property => $fieldName) {
138 138
                     $instance->$property = $row->getField($fieldName);
139 139
                 }
140 140
                 $collection[] = $instance;
@@ -156,7 +156,7 @@  discard block
 block discarded – undo
156 156
         $query->table($this->mapper->getTable())
157 157
             ->fields(array_keys($array));
158 158
 
159
-        if (empty($array[$this->mapper->getPrimaryKey()]) || count($this->get($array[$this->mapper->getPrimaryKey()])) === 0)  {
159
+        if (empty($array[$this->mapper->getPrimaryKey()]) || count($this->get($array[$this->mapper->getPrimaryKey()])) === 0) {
160 160
             $array[$this->mapper->getPrimaryKey()] = $this->insert($query, $array);
161 161
             BinderObject::bindObject($array, $instance);
162 162
         } else {
Please login to merge, or discard this patch.
src/Query.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
      */
62 62
     public function join($table, $filter)
63 63
     {
64
-        $this->join[] = [ 'table'=>$table, 'filter'=>$filter];
64
+        $this->join[] = ['table'=>$table, 'filter'=>$filter];
65 65
         return $this;
66 66
     }
67 67
 
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
      */
76 76
     public function where($filter, array $params = [])
77 77
     {
78
-        $this->where[] = [ 'filter' => $filter, 'params' => $params  ];
78
+        $this->where[] = ['filter' => $filter, 'params' => $params];
79 79
         return $this;
80 80
     }
81 81
 
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
             return null;
161 161
         }
162 162
         
163
-        return [ implode(' AND ', $where), $params ];
163
+        return [implode(' AND ', $where), $params];
164 164
     }
165 165
 
166 166
     /**
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
             $sql .= ' FOR UPDATE ';
192 192
         } 
193 193
         
194
-        return [ 'sql' => $sql, 'params' => $params ];
194
+        return ['sql' => $sql, 'params' => $params];
195 195
     }
196 196
 
197 197
     /**
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
             . implode(', ', $fields)
238 238
             . ' WHERE ' . $where[0];
239 239
 
240
-        return [ 'sql' => $sql, 'params' => $where[1] ];
240
+        return ['sql' => $sql, 'params' => $where[1]];
241 241
     }
242 242
 
243 243
     /**
@@ -254,7 +254,7 @@  discard block
 block discarded – undo
254 254
         $sql = 'DELETE FROM ' . $this->table
255 255
             . ' WHERE ' . $where[0];
256 256
 
257
-        return [ 'sql' => $sql, 'params' => $where[1] ];
257
+        return ['sql' => $sql, 'params' => $where[1]];
258 258
     }
259 259
 
260 260
 }
Please login to merge, or discard this patch.