ZF-10676: getList() doesn't return array if no translations are available in adapter

Description

PHPdoc comment for Zend_Translate_Adapter::getList() declares that method will always return array, but in a case if there is no translations are available in adapter it returns NULL.

From source code:

/**
 * Returns the available languages from this adapter
 *
 * @return array
 */
public function getList()
{
    $list = array_keys($this->_translate);
    $result = null;    // <--- This is wrong, it should be $result = array();
    foreach($list as $value) {
        if (!empty($this->_translate[$value])) {
            $result[$value] = $value;
        }
    }
    return $result;
}

Comments

Here is small patch to fix this typo bug

Check my trivial patch, plz.

Fixed with SVN:r23517 and SVN:r23518

Fixed with 11.Dec. Accepted for ZF2 with 17.Dec.

Note that the patch for 1.11 is incorrect