[FEATURE] arrayExport() should recognize int keys
authorChristian Kuhn <lolli@schwarzbu.ch>
Sat, 28 Jul 2012 17:08:23 +0000 (19:08 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Sun, 29 Jul 2012 16:47:25 +0000 (18:47 +0200)
commit04857a5d14eb52e3436bfbb2e17612870654f54d
tree8fa84d15aa0b48eaacb12bbddba694ec2c8a6eb2
parent11c44c587397c22d7461225b4afa62710c3e40dd
[FEATURE] arrayExport() should recognize int keys

t3lib_utility_Array::arrayExport() currently exports array keys always
as strings. With the patch integer array keys are now recognized and
written as integers. Additionally, if all array keys are integers and
consecutive from zero to n, the key is left out completly. See the
unit tests for details.

This is useful for the extListArray in LocalConfiguration, which now
misses the array key and makes the array even more easy to handle.

Change-Id: I6233798a8d22257f542c575791f95226220703ca
Resolves: #39134
Releases: 6.0
Reviewed-on: http://review.typo3.org/13317
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters
Reviewed-by: Susanne Moog
Tested-by: Susanne Moog
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
t3lib/utility/class.t3lib_utility_array.php
tests/Unit/t3lib/utility/class.t3lib_utility_arrayTest.php