src/DataTableAbstract.php
protected function transform($results, $processed)
    {
        if (isset($this->transformer) && class_exists('Yajra\\DataTables\\Transformers\\FractalTransformer')) {
            return app('datatables.transformer')->transform(
                $results,
                $this->transformer,
                $this->serializer ?? null
            );
        }

        return Helper::transform($processed);
    }
protected function transform($results, $processed)
    {
        if (isset($this->transformer) && class_exists('Yajra\\DataTables\\Transformers\\FractalTransformer')) {
            return app('datatables.transformer')->transform(
                $results,
                $this->transformer,
                $this->serializer ?? null
            );
        }

        return Helper::transform($processed);
    }
protected function transform ( $ results , $ processed ) { if ( isset ( $ this -> transformer ) && class_exists ( 'Yajra\\DataTables\\Transformers\\FractalTransformer' ) ) { return app ( 'datatables.transformer' ) -> transform ( $ results , $ this -> transformer , $ this -> serializer ?? null ) ; } return Helper :: transform ( $ processed ) ; }
Transform output.

@param mixed $results
@param mixed $processed
@return array
Transform output .