From 44e8b43f958f9f1f118b756b89c602bf2baab692 Mon Sep 17 00:00:00 2001 From: Lewis Cowles Date: Tue, 30 Jun 2015 22:54:09 +0100 Subject: [PATCH] pass by reference bug... --- src/Spout/Reader/XLSX.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Spout/Reader/XLSX.php b/src/Spout/Reader/XLSX.php index 94b15f1..51dc73c 100644 --- a/src/Spout/Reader/XLSX.php +++ b/src/Spout/Reader/XLSX.php @@ -273,7 +273,7 @@ class XLSX extends AbstractReader { // shared strings are formatted this way: // [SHARED_STRING_INDEX] - $sharedStringIndex = intval($this->getVNodeValue(&$node)); + $sharedStringIndex = intval($this->getVNodeValue($node)); $escapedCellValue = $this->sharedStringsHelper->getStringAtIndex($sharedStringIndex); $cellValue = $escaper->unescape($escapedCellValue); return $cellValue; @@ -288,7 +288,7 @@ class XLSX extends AbstractReader */ protected function formatStrCellValue(&$node, &$escaper) { - $escapedCellValue = trim($this->getVNodeValue(&$node)); + $escapedCellValue = trim($this->getVNodeValue($node)); $cellValue = $escaper->unescape($escapedCellValue); return $cellValue; } @@ -302,7 +302,7 @@ class XLSX extends AbstractReader */ protected function formatNumericCellValue(&$node) { - $nodeValue = $this->getVNodeValue(&$node); + $nodeValue = $this->getVNodeValue($node); $cellValue = is_int($nodeValue) ? intval($nodeValue) : floatval($nodeValue); return $cellValue; } @@ -316,7 +316,7 @@ class XLSX extends AbstractReader protected function formatBooleanCellValue(&$node) { // !! is similar to boolval() - $cellValue = (!!$this->getVNodeValue(&$node)); + $cellValue = (!!$this->getVNodeValue($node)); return $cellValue; } @@ -331,7 +331,7 @@ class XLSX extends AbstractReader { // Mitigate thrown Exception on invalid date-time format (http://php.net/manual/en/datetime.construct.php) try { - $cellValue = new \DateTime($this->getVNodeValue(&$node)); + $cellValue = new \DateTime($this->getVNodeValue($node)); return $cellValue; } catch ( \Exception $e ) { // Maybe do something... Not famiiar enough to see about exceptions at this stage