Fix validate method.