From e525c695dd139c5618139efeee84cbf8f6966a65 Mon Sep 17 00:00:00 2001 From: Filippo Tessarotto Date: Sun, 25 Nov 2012 09:01:45 +0100 Subject: [PATCH] Fix key dereferencing --- Classes/PHPExcel/Worksheet/AutoFilter.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Classes/PHPExcel/Worksheet/AutoFilter.php b/Classes/PHPExcel/Worksheet/AutoFilter.php index 2448d35d..c39bfbf8 100644 --- a/Classes/PHPExcel/Worksheet/AutoFilter.php +++ b/Classes/PHPExcel/Worksheet/AutoFilter.php @@ -826,20 +826,20 @@ class PHPExcel_Worksheet_AutoFilter if (is_object($value)) { if ($key == '_workSheet') { // Detach from worksheet - $this->$key = NULL; + $this->{$key} = NULL; } else { - $this->$key = clone $value; + $this->{$key} = clone $value; } } elseif ((is_array($value)) && ($key == '_columns')) { // The columns array of PHPExcel_Worksheet_AutoFilter objects - $this->$key = array(); + $this->{$key} = array(); foreach ($value as $k => $v) { - $this->$key[$k] = clone $v; + $this->{$key}[$k] = clone $v; // attach the new cloned Column to this new cloned Autofilter object - $this->$key[$k]->setParent($this); + $this->{$key}[$k]->setParent($this); } } else { - $this->$key = $value; + $this->{$key} = $value; } } }