more cleanup & refining