Fixes and more cleanup