Fixed previous commit that was broken in PHP 5.3.x