minor fixes all over the place