Skip to content

Commit 42b1d67

Browse files
Merge pull request #5366 from LibreSign/backport/5356/stable30
[stable30] chore: convert the date object to json
2 parents 017f4a1 + 1841e7a commit 42b1d67

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/Handler/SignEngine/SignEngineHandler.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,10 @@ public function getLastSignedDate(): \DateTime {
221221
// Prevent accepting certificates with future signing dates (possible clock issues)
222222
$dateTime = new \DateTime();
223223
if ($last['signingTime'] > $dateTime) {
224-
$this->logger->error('We found Marty McFly', ['last_signature' => $last['signingTime'], 'current_date_time' => $dateTime]);
224+
$this->logger->error('We found Marty McFly', [
225+
'last_signature' => json_encode($last['signingTime']),
226+
'current_date_time' => json_encode($dateTime),
227+
]);
225228
throw new \UnexpectedValueException('Invalid signingTime in certificate chain. We found Marty McFly');
226229
}
227230

0 commit comments

Comments
 (0)