Fix warning

This commit is contained in:
Laurent Destailleur
2025-10-24 23:05:49 +02:00
parent cd2f4bb7d2
commit 729e19cecb

View File

@@ -5785,8 +5785,8 @@ function img_picto($titlealt, $picto, $moreatt = '', $pictoisfullpath = 0, $srco
if ($type == 'main') { if ($type == 'main') {
continue; continue;
} }
// This need a lot of time, that's why enabling alternative dir like "custom" dir is not recommended // This consumes a lot of time, that's why enabling alternative dir like "custom" dir should be avoid
if (file_exists($dirroot . '/' . $path . '/img/' . $picto)) { if (file_exists($dirroot . '/' . $path . '/img/' . $picto) && !empty($conf->file->dol_url_root)) {
$url = DOL_URL_ROOT . $conf->file->dol_url_root[$type]; $url = DOL_URL_ROOT . $conf->file->dol_url_root[$type];
break; break;
} }