Use isModEnabled

This commit is contained in:
Alexandre SPANGARO
2022-09-25 15:27:42 +02:00
parent 58e96a1db8
commit c674f00cb2
5 changed files with 5 additions and 5 deletions

View File

@@ -1441,7 +1441,7 @@ class Setup extends DolibarrApi
{
global $conf;
if (empty($conf->socialnetworks->enabled)) {
if (!isModEnabled('socialnetworks')) {
throw new RestException(400, 'API not available: this dictionary is not enabled by setup');
}