[BUGFIX] Fix resource exceptions 43/31743/4
authorHelmut Hummel <helmut.hummel@typo3.org>
Wed, 23 Jul 2014 18:50:56 +0000 (20:50 +0200)
committerAnja Leichsenring <aleichsenring@ab-softlab.de>
Thu, 24 Jul 2014 13:08:35 +0000 (15:08 +0200)
commit74b0ce8e3a0e4403be90166221aacea7797c952a
tree0d5ea2d3acb392f936679ceea275867437ad6c74
parent74857fb0e4cb259b6cc8dabf8aced3e3679a2384
[BUGFIX] Fix resource exceptions

When rendering the FILES content object,
exceptions due to missing file references and missing collections
are meant to be caught. However they are not, because
InvalidArgumentException and RuntimeException are thrown instead of
ResourceDoesNotExistException

Throw the appropriate exceptions instead and also
fix a wrong check in RecordCollection Repository, where
the return type is checked against NULL while the DB
call returns FALSE when no record is found.

Resolves: #60506
Releases: 6.2, 6.3
Change-Id: I9cea492d814850f75549d280c2de0defc8b91548
Reviewed-on: http://review.typo3.org/31743
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Susanne Moog <typo3@susannemoog.de>
Tested-by: Susanne Moog <typo3@susannemoog.de>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
typo3/sysext/core/Classes/Collection/RecordCollectionRepository.php
typo3/sysext/core/Classes/Resource/FileCollectionRepository.php
typo3/sysext/core/Classes/Resource/ResourceFactory.php