code cleanup. now indented