indentation fixes and dead code removal