[TYPO3-mvc] Bug in Tx_Extbase_Reflection_ObjectAccess

Andreas Weis andreas at tollwerk.de
Wed Jun 23 13:05:02 CEST 2010


Hello everybody,

after updating to TYPO3 4.4 I found a bug in the getPropertyPath method 
in Tx_Extbase_Reflection_ObjectAccess. I couldn't access ArrayAcces 
objects anymore. However, there was only one condition missing - I 
patched it myself, and maybe it'll be patched in future extbase.


I just added the missing condition for ArrayAccess-Objects:
--------------------------------------------------------------------------
elseif (($subject instanceof ArrayAccess) && isset($subject[$pathSegment])){
	$subject = self::getProperty($subject, $pathSegment);
}
--------------------------------------------------------------------------
after
--------------------------------------------------------------------------
elseif (is_array($subject) && array_key_exists($pathSegment, $subject)) {
	$subject = self::getProperty($subject, $pathSegment);
}


maybe this helps someone with the same problem.


Have a nice week everybody!



P.S. Go Germany! :-)


More information about the TYPO3-project-typo3v4mvc mailing list