Fix PHP warnings