From bc9cc77cde4330b3c387d20ad8628009fd4049cc Mon Sep 17 00:00:00 2001 From: Benjamin Renard Date: Fri, 29 Jan 2021 12:30:59 +0100 Subject: [PATCH] LSattr_ldap::shadowExpire: fix to rounding method to avoid date change --- src/includes/class/class.LSattr_ldap_shadowExpire.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/includes/class/class.LSattr_ldap_shadowExpire.php b/src/includes/class/class.LSattr_ldap_shadowExpire.php index 7b822bf8..dfe406e5 100644 --- a/src/includes/class/class.LSattr_ldap_shadowExpire.php +++ b/src/includes/class/class.LSattr_ldap_shadowExpire.php @@ -52,7 +52,7 @@ class LSattr_ldap_shadowExpire extends LSattr_ldap { public function getUpdateData($data) { $ret=array(); foreach(ensureIsArray($data) as $val) - $ret[] = strval(floor(intval($val) / 86400)); + $ret[] = strval(round(intval($val) / 86400)); self :: log_debug($this."->getUpdateData(): input data=".varDump($data)." / update data=".varDump($ret)); return $ret; }