refactored Location validator