more tweaks and cleaning up