Code Duplication    Length = 10-10 lines in 2 locations

src/Services/DataTable.php 2 locations

@@ 145-154 (lines=10) @@
142
     *
143
     * @return array
144
     */
145
    protected function getDataForExport()
146
    {
147
        return array_map(function ($row) {
148
            if ($columns = $this->exportColumns()) {
149
                return (new DataTransformer())->transform($row, $columns, 'exportable');
150
            }
151
152
            return $row;
153
        }, $this->getAjaxResponseData());
154
    }
155
156
    /**
157
     * Get export columns definition.
@@ 249-258 (lines=10) @@
246
     *
247
     * @return array
248
     */
249
    protected function getDataForPrint()
250
    {
251
        return array_map(function ($row) {
252
            if ($columns = $this->printColumns()) {
253
                return (new DataTransformer())->transform($row, $columns, 'printable');
254
            }
255
256
            return $row;
257
        }, $this->getAjaxResponseData());
258
    }
259
260
    /**
261
     * Get printable columns.