Actions
Bug #24104
closedReplace exec_SELECTgetRows with exec_SELECTgetSingleRow whenever a single record is expected
Start date:
2010-11-17
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
4.5
PHP Version:
5.2
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
In the core the method exec_SELECTgetRows is used to fetch records from the DB. Often this method is uses, even though there is just one single record expected as a result.
Attached patch replaces exec_SELECT-getRows with exec_SELECTgetSingleRow for each case dealing with single records.
Indicators are:
list(blah) is used in front of exec_SELECTgetRows
$blah0 is used only
array_shift is used and the rest of the array stays untouched
LIMIT 1 is used within the method
and the array is not used with any foreach loop.
(issue imported from #M16445)
Files
Actions