Merge pull request #11355 from ptibogxiv/patch-190

Fix access category API
This commit is contained in:
Laurent Destailleur 2019-06-20 03:10:11 +02:00 committed by GitHub
commit ca4b8f9540
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -86,7 +86,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);
}