2
0
forked from Wavyzz/dolibarr

fix php8 warning

sometimes $size == '' and cause warnings later in the code
This commit is contained in:
Frédéric FRANCE
2021-03-16 22:01:59 +01:00
committed by GitHub
parent 22ed95a629
commit dde51a23f0

View File

@@ -3391,7 +3391,7 @@ function dol_trunc($string, $size = 40, $trunc = 'right', $stringencoding = 'UTF
{
global $conf;
if ($size == 0 || !empty($conf->global->MAIN_DISABLE_TRUNC)) {
if (empty($size) || !empty($conf->global->MAIN_DISABLE_TRUNC)) {
return $string;
}