Fix some errors and indentation