aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/smarty/smarty/libs/plugins/shared.make_timestamp.php
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/smarty/smarty/libs/plugins/shared.make_timestamp.php')
-rw-r--r--vendor/smarty/smarty/libs/plugins/shared.make_timestamp.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/vendor/smarty/smarty/libs/plugins/shared.make_timestamp.php b/vendor/smarty/smarty/libs/plugins/shared.make_timestamp.php
index 67f862441..eb064607d 100644
--- a/vendor/smarty/smarty/libs/plugins/shared.make_timestamp.php
+++ b/vendor/smarty/smarty/libs/plugins/shared.make_timestamp.php
@@ -7,7 +7,7 @@
*/
/**
- * Function: smarty_make_timestamp<br>
+ * Function: smarty_make_timestamp
* Purpose: used by other smarty functions to make a timestamp from a string.
*
* @author Monte Ohrt <monte at ohrt dot com>
@@ -25,7 +25,7 @@ function smarty_make_timestamp($string)
(interface_exists('DateTimeInterface', false) && $string instanceof DateTimeInterface)
) {
return (int) $string->format('U'); // PHP 5.2 BC
- } elseif (strlen($string) == 14 && ctype_digit($string)) {
+ } elseif (strlen($string) === 14 && ctype_digit($string)) {
// it is mysql timestamp format of YYYYMMDDHHMMSS?
return mktime(substr($string, 8, 2), substr($string, 10, 2), substr($string, 12, 2), substr($string, 4, 2),
substr($string, 6, 2), substr($string, 0, 4));
@@ -35,7 +35,7 @@ function smarty_make_timestamp($string)
} else {
// strtotime should handle it
$time = strtotime($string);
- if ($time == - 1 || $time === false) {
+ if ($time === - 1 || $time === false) {
// strtotime() was not able to parse $string, use "now":
return time();
}