cvs: pear-core /PEAR ErrorStack.php

From: Date: Mon, 07 Feb 2005 16:28:05 +0000
Subject: cvs: pear-core /PEAR ErrorStack.php
Groups: php.pear.cvs php.pear.core 
Request: Send a blank email to pear-cvs+get-29181@lists.php.net to get a copy of this message
cellog Mon Feb 7 11:28:05 2005 EDT Modified files: /pear-core/PEAR ErrorStack.php Log: fix Bug #3322 misuse of count() in ErrorStack http://cvs.php.net/diff.php/pear-core/PEAR/ErrorStack.php?r1=1.16&r2=1.17&ty=u Index: pear-core/PEAR/ErrorStack.php diff -u pear-core/PEAR/ErrorStack.php:1.16 pear-core/PEAR/ErrorStack.php:1.17 --- pear-core/PEAR/ErrorStack.php:1.16 Sat Jan 1 16:26:30 2005 +++ pear-core/PEAR/ErrorStack.php Mon Feb 7 11:28:05 2005 @@ -17,7 +17,7 @@ // | | // +----------------------------------------------------------------------+ // -// $Id: ErrorStack.php,v 1.16 2005/01/01 21:26:30 cellog Exp $ +// $Id: ErrorStack.php,v 1.17 2005/02/07 16:28:05 cellog Exp $ /** * Error Stack Implementation @@ -910,7 +910,7 @@ $mainmsg = $stack->getErrorMessageTemplate($err['code']); } $mainmsg = str_replace('%__msg%', $err['message'], $mainmsg); - if (count($err['params'])) { + if (is_array($err['params']) && count($err['params'])) { foreach ($err['params'] as $name => $val) { if (is_array($val)) { // @ is needed in case $val is a multi-dimensional array

« previous php.pear.cvs (#29181) next »