[FOLLOWUP][BUGFIX] FAL: Do not paste a folder into itself 70/36570/2
authorWouter Wolters <typo3@wouterwolters.nl>
Sun, 1 Feb 2015 12:31:10 +0000 (13:31 +0100)
committerJigal van Hemert <jigal.van.hemert@typo3.org>
Sun, 1 Feb 2015 14:15:14 +0000 (15:15 +0100)
Add missing @throws annotation for the added function.

Also the correct exception is thrown in ResourceStorage
if it occurs anyway.

Resolves: #51670
Releases: master, 6.2
Change-Id: I52551012c88326cc3fd58d2e72e53f58fedb334b
Reviewed-on: http://review.typo3.org/36570
Reviewed-by: Oliver Klee <typo3-coding@oliverklee.de>
Tested-by: Oliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: Andreas Fernandez <andreas.fernandez@aspedia.de>
Tested-by: Andreas Fernandez <andreas.fernandez@aspedia.de>
Reviewed-by: Jigal van Hemert <jigal.van.hemert@typo3.org>
Tested-by: Jigal van Hemert <jigal.van.hemert@typo3.org>
typo3/sysext/core/Classes/Resource/ResourceStorage.php

index dd3312c..bba4462 100644 (file)
@@ -2034,6 +2034,7 @@ class ResourceStorage implements ResourceStorageInterface {
         * @param Folder $folder
         * @param ResourceInterface $resource
         * @return bool
+        * @throws \InvalidArgumentException
         */
        public function isWithinFolder(Folder $folder, ResourceInterface $resource) {
                if ($folder->getStorage() !== $this) {