-purge cache after update if cache directory is set to default
-another fixes of php errors and notices