Implement some validation