From 9867da21321d310501342cfb517c298134132f0d Mon Sep 17 00:00:00 2001 From: Mathias Brodala <mbrodala@pagemachine.de> Date: Mon, 26 Feb 2024 13:00:34 +0100 Subject: [PATCH] [BUGFIX] Restore FileInterface::setContents() TODO comments MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Resolves: #103202 Releases: main, 12.4 Related: #40096 Change-Id: If64a5d16da9d500180d070b8d5f6a7fd96609010 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/83135 Tested-by: Stefan Bürk <stefan@buerk.tech> Reviewed-by: Stefan Bürk <stefan@buerk.tech> Tested-by: core-ci <typo3@b13.com> Tested-by: Garvin Hicking <gh@faktor-e.de> Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch> Tested-by: Christian Kuhn <lolli@schwarzbu.ch> Reviewed-by: Andreas Kienast <a.fernandez@scripting-base.de> Reviewed-by: Garvin Hicking <gh@faktor-e.de> Tested-by: Andreas Kienast <a.fernandez@scripting-base.de> --- typo3/sysext/core/Classes/Resource/FileInterface.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/typo3/sysext/core/Classes/Resource/FileInterface.php b/typo3/sysext/core/Classes/Resource/FileInterface.php index 3f26a7413142..d7f0a413f962 100644 --- a/typo3/sysext/core/Classes/Resource/FileInterface.php +++ b/typo3/sysext/core/Classes/Resource/FileInterface.php @@ -96,8 +96,12 @@ interface FileInterface extends ResourceInterface /** * Replace the current file contents with the given string. * - * @TODO : Consider to remove this function from the interface, as its - * @TODO : At the same time, it could be considered whether to make the whole + * @todo: Consider to remove this function from the interface, as its + * implementation in FileInUse could cause unforseen side-effects by setting + * contents on the original file instead of just on the Usage of the file. + * @todo: At the same time, it could be considered whether to make the whole + * interface a read-only FileInterface, so that all file management and + * modification functions are removed... * @return $this */ public function setContents(string $contents): self; -- GitLab