Validation checking added