Commit 8a4db9ff authored by Taylor Otwell's avatar Taylor Otwell

fixed attribute setting bug in hydrator.

parent c751844a
......@@ -49,8 +49,9 @@ class Hydrator {
foreach ($results as $result)
{
$model = new $class((array) $result);
$model = new $class;
$model->attributes = (array) $result;
$model->exists = true;
// -----------------------------------------------------
......@@ -240,8 +241,9 @@ class Hydrator {
// -----------------------------------------------------
foreach ($children as $child)
{
$related = new $class((array) $child);
$related = new $class;
$related->attributes = (array) $child;
$related->exists = true;
// -----------------------------------------------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment