• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Not a bug XenForo_Option_AdminSearchExclusions::verifyOption - unused parameter

James

Well-known member
#1
PHP:
public static function verifyOption(array &$choices, XenForo_DataWriter $dw, $fieldName)
	{
		if ($dw->isInsert())
		{
			// insert - just trust the default value
			return true;
		}

		$exclusions = array();

		foreach (XenForo_Model::create('XenForo_Model_AdminSearch')->getAllSearchTypes() AS $searchType => $handlerName)
		{
			if (empty($choices[$searchType]))
			{
				$exclusions[$searchType] = true;
			}
		}

		$choices = $exclusions;

		return true;
	}
The parameter $fieldName isn't used anywhere in the function.