fixing syntax errors in file