From 7884495d5d4df892f7d74dfe3c3e903964680d61 Mon Sep 17 00:00:00 2001 From: Andrey Mironov Date: Tue, 30 Oct 2012 16:46:23 +0600 Subject: [PATCH] Use in_array in PHPExcel::cellXfExists() --- Classes/PHPExcel.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/Classes/PHPExcel.php b/Classes/PHPExcel.php index f60a15c..ab3396b 100644 --- a/Classes/PHPExcel.php +++ b/Classes/PHPExcel.php @@ -615,12 +615,7 @@ class PHPExcel */ public function cellXfExists($pCellStyle = null) { - foreach ($this->_cellXfCollection as $cellXf) { - if ($cellXf === $pCellStyle) { - return true; - } - } - return false; + return in_array($pCellStyle, $this->_cellXfCollection, true); } /**