Fixed formatting and eliminated redundant lines