Fixing errors before compiling