Fix  inside callback for php < 5.4