Minor fixes and clean ups