forked from Wavyzz/dolibarr
Merge pull request #10936 from aspangaro/10.0_WARNING
LOG_WARNING on function dol_print_date with deprecated value
This commit is contained in:
@@ -142,12 +142,12 @@ class AccountancySystem
|
|||||||
$result = $this->rowid;
|
$result = $this->rowid;
|
||||||
} else {
|
} else {
|
||||||
$result = - 2;
|
$result = - 2;
|
||||||
$this->error = "AccountancySystem::Create Erreur $result";
|
$this->error = "AccountancySystem::Create Error $result";
|
||||||
dol_syslog($this->error, LOG_ERR);
|
dol_syslog($this->error, LOG_ERR);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$result = - 1;
|
$result = - 1;
|
||||||
$this->error = "AccountancySystem::Create Erreur $result";
|
$this->error = "AccountancySystem::Create Error $result";
|
||||||
dol_syslog($this->error, LOG_ERR);
|
dol_syslog($this->error, LOG_ERR);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1785,7 +1785,7 @@ function dol_print_date($time, $format = '', $tzoutput = 'tzserver', $outputlang
|
|||||||
|| preg_match('/^([0-9][0-9][0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])$/i', $time, $reg)) // Deprecated. Ex: 1970-01-01, 1970-01-01 01:00:00, 19700101010000
|
|| preg_match('/^([0-9][0-9][0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])$/i', $time, $reg)) // Deprecated. Ex: 1970-01-01, 1970-01-01 01:00:00, 19700101010000
|
||||||
{
|
{
|
||||||
// TODO Remove this. This part of code should not be used.
|
// TODO Remove this. This part of code should not be used.
|
||||||
dol_syslog("Functions.lib::dol_print_date function call with deprecated value of time in page ".$_SERVER["PHP_SELF"], LOG_ERR);
|
dol_syslog("Functions.lib::dol_print_date function call with deprecated value of time in page ".$_SERVER["PHP_SELF"], LOG_WARNING);
|
||||||
//if (function_exists('debug_print_backtrace')) debug_print_backtrace();
|
//if (function_exists('debug_print_backtrace')) debug_print_backtrace();
|
||||||
// Date has format 'YYYY-MM-DD' or 'YYYY-MM-DD HH:MM:SS' or 'YYYYMMDDHHMMSS'
|
// Date has format 'YYYY-MM-DD' or 'YYYY-MM-DD HH:MM:SS' or 'YYYYMMDDHHMMSS'
|
||||||
$syear = (! empty($reg[1]) ? $reg[1] : '');
|
$syear = (! empty($reg[1]) ? $reg[1] : '');
|
||||||
|
|||||||
Reference in New Issue
Block a user