fixing a validation error