added a validation