clean code
This commit is contained in:
parent
5b90302bf8
commit
53d2757a8f
@ -368,8 +368,7 @@ class MyObject extends CommonObject
|
|||||||
$result = $object->createCommon($user);
|
$result = $object->createCommon($user);
|
||||||
if ($result < 0) {
|
if ($result < 0) {
|
||||||
$error++;
|
$error++;
|
||||||
$this->error = $object->error;
|
$this->setErrorsFromObject($object);
|
||||||
$this->errors = $object->errors;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$error) {
|
if (!$error) {
|
||||||
@ -1056,8 +1055,7 @@ class MyObject extends CommonObject
|
|||||||
$result = $objectline->fetchAll('ASC', 'position', 0, 0, array('customsql'=>'fk_myobject = '.((int) $this->id)));
|
$result = $objectline->fetchAll('ASC', 'position', 0, 0, array('customsql'=>'fk_myobject = '.((int) $this->id)));
|
||||||
|
|
||||||
if (is_numeric($result)) {
|
if (is_numeric($result)) {
|
||||||
$this->error = $objectline->error;
|
$this->setErrorsFromObject($objectline);
|
||||||
$this->errors = $objectline->errors;
|
|
||||||
return $result;
|
return $result;
|
||||||
} else {
|
} else {
|
||||||
$this->lines = $result;
|
$this->lines = $result;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user