Fix Errors and Correct Formating