Skip to content

Commit

Permalink
Change __DIR__ to dirname(__FILE__) in order to works with PHP 5.…
Browse files Browse the repository at this point in the history
…2.4+


The magic constant `__DIR__` was added in PHP 5.3.0, as said here: http://php.net/manual/en/language.constants.predefined.php
  • Loading branch information
rogeriopradoj committed May 2, 2012
1 parent cb2c683 commit 491b2fd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libraries/Twiggy.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* @copyright Copyright (c) 2012 Edmundas Kondrašovas <[email protected]>
*/

if(!defined('TWIGGY_ROOT')) define('TWIGGY_ROOT', dirname(__DIR__));
if(!defined('TWIGGY_ROOT')) define('TWIGGY_ROOT', dirname(dirname(__FILE__)));

require_once(TWIGGY_ROOT . '/vendor/Twig/lib/Twig/Autoloader.php');
Twig_Autoloader::register();
Expand Down

0 comments on commit 491b2fd

Please sign in to comment.