Refactored is_x boolean methods in unit module.