[Templating] Fix for getting the file link format from XDebug settings

This commit is contained in:
Victor Berchet 2011-04-05 10:33:14 +02:00
parent 6faacdec27
commit 170375a946

View File

@ -31,7 +31,7 @@ class CodeHelper extends Helper
*/ */
public function __construct($fileLinkFormat, $rootDir) public function __construct($fileLinkFormat, $rootDir)
{ {
$this->fileLinkFormat = null !== $fileLinkFormat ? $fileLinkFormat : ini_get('xdebug.file_link_format'); $this->fileLinkFormat = empty($fileLinkFormat) ? ini_get('xdebug.file_link_format') : $fileLinkFormat;
$this->rootDir = str_replace('\\', '/', $rootDir).'/'; $this->rootDir = str_replace('\\', '/', $rootDir).'/';
} }