Fix API_ENDPOINT_RULES with api of external modules

This commit is contained in:
Laurent Destailleur 2022-02-09 17:50:26 +01:00
parent c7f99f140e
commit fe01f75e97

View File

@ -304,7 +304,7 @@ if (!empty($reg[1]) && ($reg[1] != 'explorer' || ($reg[2] != '/swagger.json' &&
foreach ($listofendpoints as $endpointrule) {
$tmparray = explode(':', $endpointrule);
if ($classfile == $tmparray[0] && $tmparray[1] == 1) {
if (($classfile == $tmparray[0] || $classfile.'api' == $tmparray[0]) && $tmparray[1] == 1) {
$endpointisallowed = true;
break;
}