house keep clear white space, refactor