Fixed Resource Manager: _deleteFromIndex

Chris D

XenForo developer
Staff member
In XenResource_Search_DataHandler_Update:

PHP:
	protected function _deleteFromIndex(XenForo_Search_Indexer $indexer, array $dataList)
	{
		$updateIds = array();
		foreach ($dataList AS $data)
		{
			if (!is_array($data))
			{
				$updateIds[] = $data['resource_update_id'];
			}
			else
			{
				$updateIds[] = $data;
			}
		}

		$indexer->deleteFromIndex('resource_update', $updateIds);
	}

I think this is incorrect:

PHP:
			if (!is_array($data))
			{
				$updateIds[] = $data['resource_update_id'];
			}

Should be:

PHP:
			if (is_array($data))
			{
				$updateIds[] = $data['resource_update_id'];
			}
 
Back
Top Bottom