fixing validator class