Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaurício Meneghini Fauth <mauricio@fauth.dev>2021-09-12 18:25:06 +0300
committerMaurício Meneghini Fauth <mauricio@fauth.dev>2021-09-12 18:25:06 +0300
commit3f873709782e65fa79507445fb37cbc9f3fdd6ba (patch)
treed55a7e89012045b9c82b57a55f3c68d222cf3a40
parent6276b30c2e78f677a4973381e768b6923a465b7f (diff)
Suppress strftime deprecation messages for PHP 8.1
Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
-rw-r--r--libraries/classes/Util.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/libraries/classes/Util.php b/libraries/classes/Util.php
index 1cc43fd042..0b272623c4 100644
--- a/libraries/classes/Util.php
+++ b/libraries/classes/Util.php
@@ -791,12 +791,12 @@ class Util
$date = (string) preg_replace(
'@%[aA]@',
- $dayOfWeek[(int) strftime('%w', (int) $timestamp)],
+ $dayOfWeek[(int) @strftime('%w', (int) $timestamp)],
$format
);
$date = (string) preg_replace(
'@%[bB]@',
- $month[(int) strftime('%m', (int) $timestamp) - 1],
+ $month[(int) @strftime('%m', (int) $timestamp) - 1],
$date
);
@@ -812,7 +812,7 @@ class Util
// Can return false on windows for Japanese language
// See https://github.com/phpmyadmin/phpmyadmin/issues/15830
- $ret = strftime($date, (int) $timestamp);
+ $ret = @strftime($date, (int) $timestamp);
// Some OSes such as Win8.1 Traditional Chinese version did not produce UTF-8
// output here. See https://github.com/phpmyadmin/phpmyadmin/issues/10598
if (
@@ -1820,7 +1820,7 @@ class Util
}
/* Do the replacement */
- return strtr((string) strftime($string), $replace);
+ return strtr((string) @strftime($string), $replace);
}
/**