minor bug fix, tweaks.