smaller fixes and improvements