cleaning things up,refactoring while moving code over