cleanup + fixes