Skip to content

Commit

Permalink
Require data for new object to be array and set it by default to empt…
Browse files Browse the repository at this point in the history
…y array
  • Loading branch information
dintel committed Feb 2, 2015
1 parent 6fa23e4 commit 4af0d98
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Mapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public function countObjects($table, $query = array())
* @param array $data initial values of properties of new object
* @return mixed new object of class $type or null of class $type does not exist
*/
public function newObject($table, $type, $data)
public function newObject($table, $type, array $data = array())
{
$type = $this->getFullType($type);
if (class_exists($type)) {
Expand Down

0 comments on commit 4af0d98

Please sign in to comment.