Skip to content

Commit 184855d

Browse files
authored
Merge pull request #127 from underdpt/fix_export_data_on_buildexcelfile
Use same export data if export handler extends DataTablesExportHandler
2 parents bf27009 + 70b2e93 commit 184855d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Services/DataTable.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ protected function buildExcelFile()
433433
return $this->buildFastExcelFile();
434434
}
435435

436-
if ($this->exportClass != DataTablesExportHandler::class) {
436+
if (! is_subclass_of($this->exportClass, DataTablesExportHandler::class)) {
437437
$collection = $this->getAjaxResponseData();
438438

439439
return new $this->exportClass($this->convertToLazyCollection($collection));

0 commit comments

Comments
 (0)