On _checkAccessToResource: category -> categorie
This commit is contained in:
parent
5135474232
commit
7380fa32ec
@ -226,7 +226,7 @@ class Categories extends DolibarrApi
|
||||
throw new RestException(404, 'category not found');
|
||||
}
|
||||
|
||||
if (!DolibarrApi::_checkAccessToResource('category', $this->category->id)) {
|
||||
if (!DolibarrApi::_checkAccessToResource('categorie', $this->category->id)) {
|
||||
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
||||
}
|
||||
|
||||
@ -261,7 +261,7 @@ class Categories extends DolibarrApi
|
||||
throw new RestException(404, 'category not found');
|
||||
}
|
||||
|
||||
if (!DolibarrApi::_checkAccessToResource('category', $this->category->id)) {
|
||||
if (!DolibarrApi::_checkAccessToResource('categorie', $this->category->id)) {
|
||||
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
||||
}
|
||||
|
||||
@ -750,7 +750,7 @@ class Categories extends DolibarrApi
|
||||
throw new RestException(404, 'category not found');
|
||||
}
|
||||
|
||||
if (!DolibarrApi::_checkAccessToResource('category', $this->category->id)) {
|
||||
if (!DolibarrApi::_checkAccessToResource('categorie', $this->category->id)) {
|
||||
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user