Fix for php versions < 5.3.7