updates to replace trigger_error notices with file logging