minor fixes I should have fixed long time ago