bug fixes and others