Removed a number of errors