Skip to content

Commit

Permalink
Prevent issues with Doctrine Inflector due to null string
Browse files Browse the repository at this point in the history
  • Loading branch information
tobias-93 committed Jul 22, 2019
1 parent a09b8f9 commit 60fecc7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class ExcelController extends \{{ namespace_prefix }}\{{ bundle_name }}\Controll
$sheet = $spreadsheet->setActiveSheetIndex(0);
$results = $this->getResults();
$suffix = Inflector::classify($key);
$suffix = Inflector::classify($key === null ? '' : $key);
if (!method_exists($this,"createSpreadsheetHeader$suffix")) {
// back to defaults
$key = null;
Expand Down Expand Up @@ -97,7 +97,7 @@ class ExcelController extends \{{ namespace_prefix }}\{{ bundle_name }}\Controll
$sheet = $phpExcelObject->setActiveSheetIndex(0);
$results = $this->getResults();
$suffix = Inflector::classify($key);
$suffix = Inflector::classify($key === null ? '' : $key);
if (!method_exists($this,"createExcelHeader$suffix")) {
// back to defaults
$key = null;
Expand Down

0 comments on commit 60fecc7

Please sign in to comment.