fixup output of object attributes in db error code
This commit is contained in:
parent
22310d17a4
commit
8d5c2b3129
@ -1112,8 +1112,12 @@ function common_log_objstring(&$object)
|
|||||||
$arr = $object->toArray();
|
$arr = $object->toArray();
|
||||||
$fields = array();
|
$fields = array();
|
||||||
foreach ($arr as $k => $v) {
|
foreach ($arr as $k => $v) {
|
||||||
|
if (is_object($v)) {
|
||||||
|
$fields[] = "$k='".get_class($v)."'";
|
||||||
|
} else {
|
||||||
$fields[] = "$k='$v'";
|
$fields[] = "$k='$v'";
|
||||||
}
|
}
|
||||||
|
}
|
||||||
$objstring = $object->tableName() . '[' . implode(',', $fields) . ']';
|
$objstring = $object->tableName() . '[' . implode(',', $fields) . ']';
|
||||||
return $objstring;
|
return $objstring;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user