tweaks and minor fixes