S-48999 fixed the logic for the validate function.