Updated Validation Logic