From 11b65a905f083a10933d4888c19a9d44d3612657 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Fri, 24 Feb 2017 10:21:52 +0100 Subject: [PATCH] Make sure date_create_from_format() exists Only for Roundcube 1.1 (this function does not exist on PHP < 5.3) --- program/lib/Roundcube/rcube_utils.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/program/lib/Roundcube/rcube_utils.php b/program/lib/Roundcube/rcube_utils.php index 04447f788..c711e6ca1 100644 --- a/program/lib/Roundcube/rcube_utils.php +++ b/program/lib/Roundcube/rcube_utils.php @@ -1193,7 +1193,7 @@ class rcube_utils $format = 'd-M-Y H:i:s O'; } - if (strpos($format, 'u') !== false) { + if (strpos($format, 'u') !== false && function_exists('date_create_from_format')) { $dt = number_format(microtime(true), 6, '.', ''); $dt .= '.' . date_default_timezone_get();