<commit_before><?php namespace Mobileka\L3\Engine\Grid\Filters;

use Mobileka\L3\Engine\Laravel\Lang,
	Mobileka\L3\Engine\Laravel\Helpers\Arr;

class Dropdown extends BaseComponent {

	protected $template = 'engine::grid.filters.dropdown';

	public function value($lang = '')
	{
		return Arr::searchRecursively($this->filters, 'where', $this->name);
	}

	public function options($options, $defaultValue = true)
	{
		if ($defaultValue)
		{
			$options = array(null => Lang::findLine($this->languageFile, 'not_selected')) + $options;
		}

		$this->options = $options;

		return $this;
	}

}
<commit_msg>Improves Dropdown Filter<commit_after><?php namespace Mobileka\L3\Engine\Grid\Filters;

use Mobileka\L3\Engine\Laravel\Lang;
use	Mobileka\L3\Engine\Laravel\Helpers\Arr;

class Dropdown extends BaseComponent {

	protected $template = 'engine::grid.filters.dropdown';

	public function value($lang = '')
	{
		return Arr::searchRecursively($this->filters, 'where', $this->name);
	}

	public function options($options, $defaultValue = true)
	{
		if ($this->translate)
		{
			foreach ($options as $key => $option)
			{
				$options[$key] = Lang::findLine($this->languageFile, $option);
			}
		}

		if ($defaultValue)
		{
			$options = array(null => Lang::findLine($this->languageFile, 'not_selected')) + $options;
		}

		$this->options = $options;

		return $this;
	}

}

{'fraction_non_alphanumeric': 0.1616678858814923, 'fraction_numerical': 0.0043891733723482075, 'mean_word_length': 4.583673469387755, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2879759', 'n_tokens_mistral': 497, 'n_tokens_neox': 461, 'n_words': 85}