habtm - error
Message: Trying to get property of non-object
Filename: ignitedrecord/base_php5.php
Line Number: 390
i`m try to use habtm. data load is ok, but error annoying!
so, if i`m add precheck - error gone....
if(is_object($joined_model)) // that`s it!
foreach($joined_model->child_class_helpers as $name => $hclass)
{
$o->$name = new $hclass($o); // PHP 4: $obj->$name =& new $hclass($o);
}
please check - may be error not simpy?
Filename: ignitedrecord/base_php5.php
Line Number: 390
i`m try to use habtm. data load is ok, but error annoying!
so, if i`m add precheck - error gone....
if(is_object($joined_model)) // that`s it!
foreach($joined_model->child_class_helpers as $name => $hclass)
{
$o->$name = new $hclass($o); // PHP 4: $obj->$name =& new $hclass($o);
}
please check - may be error not simpy?
Leave a comment