Fixes php notices