Updated Lint Issies
This commit is contained in:
parent
b3f078a687
commit
c2a81341ad
@ -245,8 +245,7 @@ class Categories extends DolibarrApi
|
||||
if ($this->category->update(DolibarrApiAccess::$user) > 0)
|
||||
{
|
||||
return $this->get($id);
|
||||
}
|
||||
else
|
||||
} else
|
||||
{
|
||||
throw new RestException(500, $this->category->error);
|
||||
}
|
||||
@ -324,7 +323,7 @@ class Categories extends DolibarrApi
|
||||
throw new RestException(401);
|
||||
} elseif ($type == Categorie::TYPE_MEMBER && !DolibarrApiAccess::$user->rights->adherent->lire) {
|
||||
throw new RestException(401);
|
||||
} elseif ($type == Categorie::TYPE_PROJECT && !DolibarrApiAccess::$user->rights->projet->lire) {
|
||||
} elseif ($type == Categorie::TYPE_PROJECT && !DolibarrApiAccess::$user->rights->projet->lire) {
|
||||
throw new RestException(401);
|
||||
}
|
||||
|
||||
@ -781,10 +780,10 @@ class Categories extends DolibarrApi
|
||||
} elseif ($type == 'contact') {
|
||||
$objects_api = new Contacts();
|
||||
}
|
||||
elseif ($type == 'project') {
|
||||
elseif ($type == 'project') {
|
||||
$objects_api = new Projects();
|
||||
}
|
||||
if (is_object($objects_api))
|
||||
if (is_object($objects_api))
|
||||
{
|
||||
foreach ($objects as $obj) {
|
||||
$cleaned_objects[] = $objects_api->_cleanObjectDatas($obj);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user