public function validateIDDataset($attribute, $params) { if ($this->dataset) { $this->dataset = Utils::clean2uri($this->dataset); } else { $this->addError($attribute, 'The country must be either "USA" or "Web".'); } }