validation bug fixes