[TASK] Refactor conditions in t3lib_extFileFunc
authorAndreas Wolf <andreas.wolf@ikt-werk.de>
Tue, 8 Mar 2011 07:00:37 +0000 (08:00 +0100)
committerAndreas Wolf <andreas.wolf@ikt-werk.de>
Fri, 27 May 2011 17:39:28 +0000 (19:39 +0200)
commit2585d5a060eb1196965458954b30d0b869abc58c
tree8c103ee61614ceeeb2e3f057b1b6a2665fcc3d3a
parentc61d13f6d85bc451379ee1627bf7d2f5bccf373b
[TASK] Refactor conditions in t3lib_extFileFunc

t3lib_extFileFunc has a lot of deeply nested conditions. These
conditions make understanding the code really hard.

Most of the else-branches only contain a log call, so it helps a lot to
invert the conditions, move the log call inside the if-branch and add a
break statement afterwards. The else branch can then be removed to
streamline the code.

Change-Id: Ic900fe3294142ebc89be4c3d420bb729a24d5452
Resolves: #24218
Reviewed-on: http://review.typo3.org/1087
Reviewed-by: Francois Suter
Tested-by: Francois Suter
Reviewed-by: Stefan Neufeind
t3lib/class.t3lib_extfilefunc.php