Skip to content
Snippets Groups Projects
Commit d0efa945 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Fix: A constant can't have spaces in name

parent 9e744da4
Branches
Tags
No related merge requests found
...@@ -375,6 +375,10 @@ function dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $not ...@@ -375,6 +375,10 @@ function dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $not
{ {
global $conf; global $conf;
// Clean parameters
$name=trim($name);
// Check parameters
if (empty($name)) if (empty($name))
{ {
dol_print_error("Error: Call to function dolibarr_set_const with wrong parameters", LOG_ERR); dol_print_error("Error: Call to function dolibarr_set_const with wrong parameters", LOG_ERR);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment