mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-06 01:28:19 +01:00
Fix impossibility to validate objects (#35202)
* Fix impossibility to validate objects * fix pre commit --------- Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
This commit is contained in:
committed by
GitHub
parent
3ba272b2fb
commit
5fa3ecd41a
@@ -1569,6 +1569,9 @@ function dol_buildpath($path, $type = 0, $returnemptyifnotfound = 0)
|
||||
}
|
||||
// if (@file_exists($dirroot.'/'.$path)) {
|
||||
if (@file_exists($dirroot . '/' . $path)) { // avoid [php:warn]
|
||||
if ($key != 'main' && preg_match('/^core\//', $path)) { // When searching into an alternative custom path, we don't want path like 'core/...' because path should be 'modulename/core/...'
|
||||
continue;
|
||||
}
|
||||
$res = $dirroot . '/' . $path;
|
||||
return $res;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user