[BUGFIX] Use a typecast to ensure correct value 81/37781/2
authorGeorg Ringer <georg.ringer@gmail.com>
Thu, 12 Mar 2015 08:56:48 +0000 (09:56 +0100)
committerMarkus Klein <klein.t3@reelworx.at>
Thu, 12 Mar 2015 11:12:08 +0000 (12:12 +0100)
BackendUtility::getLabelsFromItemsList must use a typecast to compare
values.

Change-Id: I6efecbd4871e8435a41aa4310c5e6db19e9bb280
Resolves: #65689
Releases: master,6.2
Reviewed-on: http://review.typo3.org/37781
Reviewed-by: Markus Klein <klein.t3@reelworx.at>
Tested-by: Markus Klein <klein.t3@reelworx.at>
typo3/sysext/backend/Classes/Utility/BackendUtility.php

index 183dc6c..1ced3a5 100644 (file)
@@ -1896,7 +1896,7 @@ class BackendUtility {
                                        foreach ($GLOBALS['TCA'][$table]['columns'][$column]['config']['items'] as $itemConfiguration) {
                                                // Loop on all available items
                                                // Keep matches and move on to next value
-                                               if ($aValue == $itemConfiguration[1]) {
+                                               if ((string)$aValue === (string)$itemConfiguration[1]) {
                                                        $labels[] = $GLOBALS['LANG']->sL($itemConfiguration[0]);
                                                        break;
                                                }