ZF-7296: Zend_Uri_Http::getPath should return false when no path exists, returns / instead
Description
/**
* Returns the path and filename portion of the URL, or FALSE if none.
*
* @return string
*/
public function getPath()
{
return strlen($this->_path) > 0 ? $this->_path : '/';
}
needs to be updated to:
public function getPath()
{
return strlen($this->_path) > 0 ? $this->_path : false;
}
Comments
Posted by Marc Hodgins (mjh_ca) on 2010-11-05T00:15:57.000+0000
More of a docblock problem, IMO. Patch is attached.
Changing behavior to return false would be a big BC break that isn't necessary.
Posted by Marc Hodgins (mjh_ca) on 2010-11-19T11:56:44.000+0000
Patch applied to trunk in r23408, merged to 1.11 release branch in r23409.