diff --git a/htdocs/admin/security.php b/htdocs/admin/security.php index 33344363cf7..e30e50769bb 100644 --- a/htdocs/admin/security.php +++ b/htdocs/admin/security.php @@ -56,8 +56,8 @@ if ($action == 'activate_encrypt') { $db->begin(); - // On old version a bug created the constant into user entity, so we delete it to be sure, such entry won't exists. We want it in entity 0 or nowhere. - dolibarr_del_const($db, "DATABASE_PWD_ENCRYPTED", "1", 'chaine', 0, '', $conf->entity); + // On old version, a bug created the constant into user entity, so we delete it to be sure such entry won't exists. We want it in entity 0 or nowhere. + dolibarr_del_const($db, "DATABASE_PWD_ENCRYPTED", $conf->entity); // We set entity=0 (all) because DATABASE_PWD_ENCRYPTED is a setup into conf file, so always shared for everybody $entityforall = 0; dolibarr_set_const($db, "DATABASE_PWD_ENCRYPTED", "1", 'chaine', 0, '', $entityforall); diff --git a/htdocs/variants/combinations.php b/htdocs/variants/combinations.php index 2d706699447..6949ccb183f 100644 --- a/htdocs/variants/combinations.php +++ b/htdocs/variants/combinations.php @@ -496,7 +496,7 @@ if (!empty($id) || !empty($ref)) { } if ($action == 'add') { - $prodattr_all = $prodattr->fetchAll(1); + $prodattr_all = $prodattr->fetchAll(); if (!$selected) { $selected = $prodattr_all[key($prodattr_all)]->id;