cvs: pear /MDB2_Schema/tests testUtils.php

From: Date: Wed, 25 Oct 2006 12:13:21 +0000
Subject: cvs: pear /MDB2_Schema/tests testUtils.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-42810@lists.php.net to get a copy of this message
lsmith Wed Oct 25 12:13:21 2006 UTC Modified files: /pear/MDB2_Schema/tests testUtils.php Log: - better deal with non scalar arguments as 5.2.0 explodes otherwise http://cvs.php.net/viewvc.cgi/pear/MDB2_Schema/tests/testUtils.php?r1=1.2&r2=1.3&diff_format=u Index: pear/MDB2_Schema/tests/testUtils.php diff -u pear/MDB2_Schema/tests/testUtils.php:1.2 pear/MDB2_Schema/tests/testUtils.php:1.3 --- pear/MDB2_Schema/tests/testUtils.php:1.2 Wed May 31 14:41:17 2006 +++ pear/MDB2_Schema/tests/testUtils.php Wed Oct 25 12:13:20 2006 @@ -59,7 +59,11 @@ $message.= $trace_item['function']; if (!empty($trace_item['args']) && is_array($trace_item['args'])) { - $message.= '('.@implode(', ', $trace_item['args']).')'; + $args = array(); + foreach ($trace_item['args'] as $arg) { + $args[] = is_scalar($arg) ? $arg : (is_object($arg) ? get_class($arg) : gettype($arg)); + } + $message.= '('.implode(', ', $args).')'; } else { $message.= '()'; }

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