MantisBT - ATutor
View Issue Details
0002479ATutor- no cat -public2006-05-31 11:402006-06-05 08:08
heidi 
user2 
normalminoralways
closedfixed 
 
1.5.3 
SVN
0002479: php 505 issues
array merge expects both arguments to be arrays and crashes if they're not.

current() in Module.class.php needs a variable that is reset() before use.

in Module::getName()
replace current($this-....)
with
$tmp = $this-
current($tmp)
No tags attached.
Issue History
2006-05-31 11:40heidiNew Issue
2006-05-31 11:40heidiAffects version => SVN
2006-06-01 08:37heidiNote Added: 0001886
2006-06-05 08:07user2Statusnew => resolved
2006-06-05 08:07user2Fixed in Version => 1.5.3
2006-06-05 08:07user2Resolutionopen => fixed
2006-06-05 08:07user2Assigned To => user2
2006-06-05 08:07user2Note Added: 0001923
2006-06-05 08:08user2Statusresolved => closed

Notes
(0001886)
heidi   
2006-06-01 08:37   
Warning

The behavior of array_merge() was modified in PHP 5. Unlike PHP 4, array_merge() now only accepts parameters of type array. However, you can use typecasting to merge other types. See the example below for details.

Example 3. array_merge() PHP 5 example
<?php
$beginning = 'foo';
$end = array(1 => 'bar');
$result = array_merge((array)$beginning, (array)$end);
print_r($result);
?>
(0001923)
user2   
2006-06-05 08:07   
casting is yuck.