Fixing fatal error in PHP 5.4