minor fixes
Fixes and improvements