Removed duplicated code from exemplary validations for password