File tree Expand file tree Collapse file tree 1 file changed +2
-14
lines changed
src/PhpSpreadsheet/Writer/Xlsx Expand file tree Collapse file tree 1 file changed +2
-14
lines changed Original file line number Diff line number Diff line change @@ -614,21 +614,9 @@ private function getPassThroughDrawingXml(\PhpOffice\PhpSpreadsheet\Worksheet\Wo
614614 }
615615
616616 $ codeName = $ worksheet ->getCodeName ();
617- if (!isset ($ unparsedLoadedData ['sheets ' ][$ codeName ])) {
618- return null ;
619- }
620-
621- $ sheetData = $ unparsedLoadedData ['sheets ' ][$ codeName ];
622- if (!is_array ($ sheetData )) {
623- return null ;
624- }
625-
617+ $ sheetData = $ unparsedLoadedData ['sheets ' ][$ codeName ] ?? null ;
626618 // Only use pass-through XML if the Reader flag was explicitly enabled
627- if (($ sheetData ['drawingPassThroughEnabled ' ] ?? false ) !== true ) {
628- return null ;
629- }
630-
631- if (!isset ($ sheetData ['Drawings ' ]) || !is_array ($ sheetData ['Drawings ' ])) {
619+ if (!is_array ($ sheetData ) || ($ sheetData ['drawingPassThroughEnabled ' ] ?? false ) !== true || !is_array ($ sheetData ['Drawings ' ] ?? null )) {
632620 return null ;
633621 }
634622
You can’t perform that action at this time.
0 commit comments