From 2f67599968ea2eb13fdadbe3b6e296a7e09d81ce Mon Sep 17 00:00:00 2001 From: Stephane V Date: Wed, 9 Jul 2014 19:18:20 +0200 Subject: [PATCH] Fix #532. Adds an intermediate variable to be compatible with php 5.3 --- lib/backend/ldap.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/backend/ldap.php b/lib/backend/ldap.php index b0318093..5d06edfc 100644 --- a/lib/backend/ldap.php +++ b/lib/backend/ldap.php @@ -604,7 +604,8 @@ class Ldap extends AbstractBackend { $uri = isset($options['uri']) ? $options['uri'] : null; - $contact->REV = (new \DateTime)->format(\DateTime::W3C); + $datetime = new \DateTime; + $contact->REV = $datetime->format(\DateTime::W3C); // 2014/02/13 Sometimes, a card is created without a name (I don't like that)... if (!isset($contact->N)) {