More cleanup

Preparing to do some major refactoring