[TASK] Fix CGL violations against SelfMemberReference
authorWouter Wolters <typo3@wouterwolters.nl>
Fri, 21 Sep 2012 17:18:37 +0000 (19:18 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Sat, 22 Sep 2012 16:00:02 +0000 (18:00 +0200)
Change-Id: Ie07b7476f5b06e8447bb1365c4af42dd2e1732b0
Resolves: #41192
Releases: 6.0
Reviewed-on: http://review.typo3.org/14854
Reviewed-by: Wouter Wolters
Reviewed-by: Philipp Gampe
Tested-by: Philipp Gampe
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
typo3/sysext/core/Classes/Utility/GeneralUtility.php
typo3/sysext/reports/Classes/Report/Status/Status.php

index 790ed18..bdc9326 100644 (file)
@@ -4946,7 +4946,7 @@ Connection: close
         * @return string the encoded value already quoted (with single quotes),
         */
        static public function quoteJSvalue($value) {
-               $escapedValue = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Core\\Encoder\\JavaScriptEncoder')->encode($value);
+               $escapedValue = static::makeInstance('TYPO3\\CMS\\Core\\Encoder\\JavaScriptEncoder')->encode($value);
                return '\'' . $escapedValue . '\'';
        }
 
index 85af9bd..6c30449 100644 (file)
@@ -104,6 +104,7 @@ class Status implements \TYPO3\CMS\Reports\ReportInterface {
        public function getHighestSeverity(array $statusCollection) {
                $highestSeverity = \TYPO3\CMS\Reports\Status::NOTICE;
                foreach ($statusCollection as $statusProvider => $providerStatuses) {
+                       /** @var $status \TYPO3\CMS\Reports\Status */
                        foreach ($providerStatuses as $status) {
                                if ($status->getSeverity() > $highestSeverity) {
                                        $highestSeverity = $status->getSeverity();
@@ -150,6 +151,7 @@ class Status implements \TYPO3\CMS\Reports\ReportInterface {
                        $messages = '';
                        $headerIcon = '';
                        $sectionSeverity = 0;
+                       /** @var $status \TYPO3\CMS\Reports\Status */
                        foreach ($providerState as $status) {
                                $severity = $status->getSeverity();
                                $sectionSeverity = $severity > $sectionSeverity ? $severity : $sectionSeverity;
@@ -216,6 +218,7 @@ class Status implements \TYPO3\CMS\Reports\ReportInterface {
        protected function sortStatuses(array $statusCollection) {
                $statuses = array();
                $sortTitle = array();
+               /** @var $status \TYPO3\CMS\Reports\Status */
                foreach ($statusCollection as $status) {
                        if ($status->getTitle() === 'TYPO3') {
                                $header = $status;