[TYPO3-core] GeneralUtility::inList() and spaces

Markus Klein klein.t3 at mfc-linz.at
Wed Jul 10 11:51:40 CEST 2013


Hi!

I suggest to use "the middle way" and just do a trim() on the values, which still does the trick without RegExp.

Kind regards
Markus

------------------------------------------------------------
Markus Klein
TYPO3 CMS Active Contributors Team Member

> -----Original Message-----
> From: typo3-team-core-bounces at lists.typo3.org [mailto:typo3-team-core-
> bounces at lists.typo3.org] On Behalf Of François Suter
> Sent: Wednesday, July 10, 2013 11:43 AM
> To: typo3-team-core at lists.typo3.org
> Subject: [TYPO3-core] GeneralUtility::inList() and spaces
> 
> Hi all,
> 
> I just stumbled on this issue: http://forge.typo3.org/issues/42789
> 
> It is due to the behavior of
> \TYPO3\CMS\Core\Utility\GeneralUtility::inList() which doesn't accept
> spaces in comma-separated strings.
> 
> I was wondering whether we should fix this or not. Accepting arbitrary
> spaces probably means using a regexp instead of strpos() which would be
> slower. And since inList() is very widely used I'm wary of making such a
> change.
> 
> Opinions?
> 
> Cheers
> 
> --
> 
> Francois Suter
> 
> Work: Cobweb Development Sarl - http://www.cobweb.ch
> 
> TYPO3: Help the project! - http://typo3.org/contribute/
> 
> Appreciate my work? Support me -
> http://www.monpetitcoin.com/en/francois/support-me/
> 
> _______________________________________________
> Before posting to this list, please have a look to the posting rules on the
> following websites:
> 
> http://typo3.org/teams/core/core-mailinglist-rules/
> http://typo3.org/development/bug-fixing/diff-and-patch/
> _______________________________________________
> TYPO3-team-core mailing list
> TYPO3-team-core at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-team-core



More information about the TYPO3-team-core mailing list