coverage and bug fixes