Project

General

Profile

Actions

Bug #28085

closed

t3lib_div::debugRows can't return data anymore

Added by Sebastian Michaelsen over 13 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Backend API
Target version:
-
Start date:
2011-07-11
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
4.6
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

In TYPO3 4.5 t3lib_div::debugRows() was deprecated and moved to t3lib_utility_Debug::debugRows()

    /**
     * Displays an array as rows in a table. Useful to debug output like an array of database records.
     *
     * @param    mixed        Array of arrays with similar keys
     * @param    string        Table header
     * @param    boolean        If TRUE, will return content instead of echo'ing out.
     * @return    void        Outputs to browser.
     * @deprecated since TYPO3 4.5 - Use t3lib_utility_Debug::debugRows instead
     */
    public static function debugRows($rows, $header = '', $returnHTML = FALSE) {
        self::logDeprecatedFunction();
        t3lib_utility_Debug::debugRows($rows, $header, $returnHTML);
    }

The problem is, that t3lib_utility_Debug::debugRows() is just called but not returned, despite the fact that debugRows() offers an option $returnHTML to return an HTML table.
So in the (a bit unlikely) case someone relies on values returned by t3lib_div::debugRows(), 4.5 broke his code.

Adding a simple "return" will solve this problem.

Actions #1

Updated by Xavier Perseguers over 13 years ago

  • Status changed from New to Accepted

Although I hate those methods with an invalid phpDoc ("@return void")

Actions #2

Updated by Mr. Hudson over 13 years ago

Patch set 1 of change I4e328db1b78975a7baed386a316dc50f00a0ac40 has been pushed to the review server.
It is available at http://review.typo3.org/3238

Actions #3

Updated by Sebastian Michaelsen over 13 years ago

Xavier Perseguers wrote:

Although I hate those methods with an invalid phpDoc ("@return void")

I have something in preparation for you ;)

Actions #4

Updated by Sebastian Michaelsen over 13 years ago

  • Status changed from Accepted to Resolved
  • % Done changed from 0 to 100
Actions #5

Updated by Benni Mack about 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF