Fix warnings
This commit is contained in:
parent
2f2349d738
commit
cc93166c53
@ -128,9 +128,9 @@ if ($action == "set" || empty($action) || preg_match('/upgrade/i', $action)) {
|
||||
$error = 0;
|
||||
|
||||
// If password is encoded, we decode it
|
||||
if (preg_match('/crypted:/i', $dolibarr_main_db_pass) || !empty($dolibarr_main_db_encrypted_pass)) {
|
||||
if ((!empty($dolibarr_main_db_pass) && preg_match('/crypted:/i', $dolibarr_main_db_pass)) || !empty($dolibarr_main_db_encrypted_pass)) {
|
||||
require_once $dolibarr_main_document_root.'/core/lib/security.lib.php';
|
||||
if (preg_match('/crypted:/i', $dolibarr_main_db_pass)) {
|
||||
if (!empty($dolibarr_main_db_pass) && preg_match('/crypted:/i', $dolibarr_main_db_pass)) {
|
||||
$dolibarr_main_db_pass = preg_replace('/crypted:/i', '', $dolibarr_main_db_pass);
|
||||
$dolibarr_main_db_pass = dol_decode($dolibarr_main_db_pass);
|
||||
$dolibarr_main_db_encrypted_pass = $dolibarr_main_db_pass; // We need to set this as it is used to know the password was initially crypted
|
||||
|
||||
@ -123,9 +123,9 @@ if (!GETPOST('action', 'aZ09') || preg_match('/upgrade/i', GETPOST('action', 'aZ
|
||||
print '<table border="0" width="100%">';
|
||||
|
||||
// If password is encoded, we decode it
|
||||
if (preg_match('/crypted:/i', $dolibarr_main_db_pass) || !empty($dolibarr_main_db_encrypted_pass)) {
|
||||
if ((!empty($dolibarr_main_db_pass) && preg_match('/crypted:/i', $dolibarr_main_db_pass)) || !empty($dolibarr_main_db_encrypted_pass)) {
|
||||
require_once $dolibarr_main_document_root.'/core/lib/security.lib.php';
|
||||
if (preg_match('/crypted:/i', $dolibarr_main_db_pass)) {
|
||||
if (!empty($dolibarr_main_db_pass) && preg_match('/crypted:/i', $dolibarr_main_db_pass)) {
|
||||
$dolibarr_main_db_pass = preg_replace('/crypted:/i', '', $dolibarr_main_db_pass);
|
||||
$dolibarr_main_db_pass = dol_decode($dolibarr_main_db_pass);
|
||||
$dolibarr_main_db_encrypted_pass = $dolibarr_main_db_pass; // We need to set this as it is used to know the password was initially crypted
|
||||
|
||||
Loading…
Reference in New Issue
Block a user