Fixed Call to deprecated method

TickTackk

Well-known member
Affected version
2.1.8
In src\XF\Util\Arr.php
PHP:
    /**
     * @deprecated No longer required as of XF 2.1.0 as all installations now run PHP 5.5+
     */
    public static function arrayColumn(array $array, $column, $index = null)
    {
        return array_column($array, $column, $index);
    }

In src\addons\XFMG\Job\AbstractBatchUpdateAction.php
PHP:
            $searcher = $this->app->searcher($this->getClassIdentifier(), $this->data['criteria']);
            $results = $searcher->getFinder()
                ->where($column, '>', $this->data['start'])
                ->order($column)
                ->limit(1000)
                ->fetchColumns($column);
            $ids = \XF\Util\Arr::arrayColumn($results, $column);
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XFMG release (2.2.0 Beta 2).

Change log:
Use native array_column function rather than deprecated polyfill
There may be a delay before changes are rolled out to the XenForo Community.
 
Back
Top Bottom