Fix bug in php 5.3