From 513371152aa5477b10b75d3b75b847f531057538 Mon Sep 17 00:00:00 2001 From: Anna Larch Date: Thu, 20 Jul 2023 16:26:48 +0200 Subject: [PATCH] fix(utility): De- deprecate getDateTime as now() only returns immutable objects This will mean lots of code like ```$dateTime = (new DateTime())->setTimestamp(ITimeFactory::now()->getTimestamp()``` if a regular DateTime object is needed Signed-off-by: Anna Larch --- lib/public/AppFramework/Utility/ITimeFactory.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/public/AppFramework/Utility/ITimeFactory.php b/lib/public/AppFramework/Utility/ITimeFactory.php index 7a6acf97b2d5c..d4f74c9d1071b 100644 --- a/lib/public/AppFramework/Utility/ITimeFactory.php +++ b/lib/public/AppFramework/Utility/ITimeFactory.php @@ -41,7 +41,6 @@ interface ITimeFactory extends ClockInterface { /** * @return int the result of a call to time() * @since 8.0.0 - * @deprecated 26.0.0 {@see ITimeFactory::now()} */ public function getTime(): int; @@ -50,7 +49,6 @@ public function getTime(): int; * @param \DateTimeZone|null $timezone * @return \DateTime * @since 15.0.0 - * @deprecated 26.0.0 {@see ITimeFactory::now()} */ public function getDateTime(string $time = 'now', \DateTimeZone $timezone = null): \DateTime;