First replacement of error message code goes fine