Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — 2.x ( c39249...68e0dd )
by Sebastian
21s queued 13s
created
common/class.tx_dlf_indexing.php 1 patch
Spacing   +32 added lines, -32 removed lines patch added patch discarded remove patch
@@ -34,14 +34,14 @@  discard block
 block discarded – undo
34 34
      * @var	array
35 35
      * @access protected
36 36
      */
37
-    protected static $fields = array (
38
-        'autocomplete' => array (),
39
-        'facets' => array (),
40
-        'sortables' => array (),
41
-        'indexed' => array (),
42
-        'stored' => array (),
43
-        'tokenized' => array (),
44
-        'fieldboost' => array ()
37
+    protected static $fields = array(
38
+        'autocomplete' => array(),
39
+        'facets' => array(),
40
+        'sortables' => array(),
41
+        'indexed' => array(),
42
+        'stored' => array(),
43
+        'tokenized' => array(),
44
+        'fieldboost' => array()
45 45
     );
46 46
 
47 47
     /**
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
      * @var	array
60 60
      * @access protected
61 61
      */
62
-    protected static $processedDocs = array ();
62
+    protected static $processedDocs = array();
63 63
 
64 64
     /**
65 65
      * Instance of tx_dlf_solr class
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
 
103 103
                     if (TYPO3_DLOG) {
104 104
 
105
-                        \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->add(['.$doc->uid.'], '.$core.')] Could not load parent document with UID "'.$doc->parentId.'"', self::$extKey, SYSLOG_SEVERITY_ERROR);
105
+                        \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->add([' . $doc->uid . '], ' . $core . ')] Could not load parent document with UID "' . $doc->parentId . '"', self::$extKey, SYSLOG_SEVERITY_ERROR);
106 106
 
107 107
                     }
108 108
 
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 
120 120
                 // Delete old Solr documents.
121 121
                 $updateQuery = self::$solr->service->createUpdate();
122
-                $updateQuery->addDeleteQuery('uid:'.$doc->uid);
122
+                $updateQuery->addDeleteQuery('uid:' . $doc->uid);
123 123
                 self::$solr->service->update($updateQuery);
124 124
 
125 125
                 // Index every logical unit as separate Solr document.
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
                 $result = $GLOBALS['TYPO3_DB']->exec_SELECTquery(
166 166
                     'tx_dlf_documents.title AS title',
167 167
                     'tx_dlf_documents',
168
-                    'tx_dlf_documents.uid='.intval($doc->uid).tx_dlf_helper::whereClause('tx_dlf_documents'),
168
+                    'tx_dlf_documents.uid=' . intval($doc->uid) . tx_dlf_helper::whereClause('tx_dlf_documents'),
169 169
                     '',
170 170
                     '',
171 171
                     '1'
@@ -209,7 +209,7 @@  discard block
 block discarded – undo
209 209
 
210 210
                     $message = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
211 211
                         'TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
212
-                        tx_dlf_helper::getLL('flash.solrException', TRUE).'<br />'.htmlspecialchars($e->getMessage()),
212
+                        tx_dlf_helper::getLL('flash.solrException', TRUE) . '<br />' . htmlspecialchars($e->getMessage()),
213 213
                         tx_dlf_helper::getLL('flash.error', TRUE),
214 214
                         \TYPO3\CMS\Core\Messaging\FlashMessage::ERROR,
215 215
                         TRUE
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
 
222 222
                 if (TYPO3_DLOG) {
223 223
 
224
-                    \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->add(['.$doc->uid.'], '.$core.')] Apache Solr threw exception: "'.$e->getMessage().'"', self::$extKey, SYSLOG_SEVERITY_ERROR);
224
+                    \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->add([' . $doc->uid . '], ' . $core . ')] Apache Solr threw exception: "' . $e->getMessage() . '"', self::$extKey, SYSLOG_SEVERITY_ERROR);
225 225
 
226 226
                 }
227 227
 
@@ -247,7 +247,7 @@  discard block
 block discarded – undo
247 247
 
248 248
             if (TYPO3_DLOG) {
249 249
 
250
-                \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->add(['.$doc->uid.'], '.$core.')] Could not connect to Apache Solr server', self::$extKey, SYSLOG_SEVERITY_ERROR);
250
+                \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->add([' . $doc->uid . '], ' . $core . ')] Could not connect to Apache Solr server', self::$extKey, SYSLOG_SEVERITY_ERROR);
251 251
 
252 252
             }
253 253
 
@@ -278,7 +278,7 @@  discard block
 block discarded – undo
278 278
         $result = $GLOBALS['TYPO3_DB']->exec_SELECTquery(
279 279
             'tx_dlf_solrcores.uid AS uid,tx_dlf_documents.title AS title',
280 280
             'tx_dlf_solrcores,tx_dlf_documents',
281
-            'tx_dlf_solrcores.uid=tx_dlf_documents.solrcore AND tx_dlf_documents.uid='.$uid.tx_dlf_helper::whereClause('tx_dlf_solrcores'),
281
+            'tx_dlf_solrcores.uid=tx_dlf_documents.solrcore AND tx_dlf_documents.uid=' . $uid . tx_dlf_helper::whereClause('tx_dlf_solrcores'),
282 282
             '',
283 283
             '',
284 284
             '1'
@@ -295,7 +295,7 @@  discard block
 block discarded – undo
295 295
 
296 296
                     // Delete Solr document.
297 297
                     $updateQuery = self::$solr->service->createUpdate();
298
-                    $updateQuery->addDeleteQuery('uid:'.$uid);
298
+                    $updateQuery->addDeleteQuery('uid:' . $uid);
299 299
                     $updateQuery->addCommit();
300 300
                     self::$solr->service->update($updateQuery);
301 301
 
@@ -305,7 +305,7 @@  discard block
 block discarded – undo
305 305
 
306 306
                         $message = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
307 307
                             'TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
308
-                            tx_dlf_helper::getLL('flash.solrException', TRUE).'<br />'.htmlspecialchars($e->getMessage()),
308
+                            tx_dlf_helper::getLL('flash.solrException', TRUE) . '<br />' . htmlspecialchars($e->getMessage()),
309 309
                             tx_dlf_helper::getLL('flash.error', TRUE),
310 310
                             \TYPO3\CMS\Core\Messaging\FlashMessage::ERROR,
311 311
                             TRUE
@@ -317,7 +317,7 @@  discard block
 block discarded – undo
317 317
 
318 318
                     if (TYPO3_DLOG) {
319 319
 
320
-                        \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->delete('.$_uid.')] Apache Solr threw exception: "'.$e->getMessage().'"', self::$extKey, SYSLOG_SEVERITY_ERROR);
320
+                        \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->delete(' . $_uid . ')] Apache Solr threw exception: "' . $e->getMessage() . '"', self::$extKey, SYSLOG_SEVERITY_ERROR);
321 321
 
322 322
                     }
323 323
 
@@ -343,7 +343,7 @@  discard block
 block discarded – undo
343 343
 
344 344
                 if (TYPO3_DLOG) {
345 345
 
346
-                    \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->delete('.$_uid.')] Could not connect to Apache Solr server', self::$extKey, SYSLOG_SEVERITY_ERROR);
346
+                    \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->delete(' . $_uid . ')] Could not connect to Apache Solr server', self::$extKey, SYSLOG_SEVERITY_ERROR);
347 347
 
348 348
                 }
349 349
 
@@ -371,7 +371,7 @@  discard block
 block discarded – undo
371 371
 
372 372
             if (TYPO3_DLOG) {
373 373
 
374
-                \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->delete('.$_uid.')] Invalid UID "'.$uid.'" for document deletion', self::$extKey, SYSLOG_SEVERITY_ERROR);
374
+                \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->delete(' . $_uid . ')] Invalid UID "' . $uid . '" for document deletion', self::$extKey, SYSLOG_SEVERITY_ERROR);
375 375
 
376 376
             }
377 377
 
@@ -403,7 +403,7 @@  discard block
 block discarded – undo
403 403
 
404 404
             if (TYPO3_DLOG) {
405 405
 
406
-                \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->getIndexFieldName('.$index_name.', '.$_pid.')] Invalid PID "'.$pid.'" for metadata configuration', self::$extKey, SYSLOG_SEVERITY_ERROR);
406
+                \TYPO3\CMS\Core\Utility\GeneralUtility::devLog('[tx_dlf_indexing->getIndexFieldName(' . $index_name . ', ' . $_pid . ')] Invalid PID "' . $pid . '" for metadata configuration', self::$extKey, SYSLOG_SEVERITY_ERROR);
407 407
 
408 408
             }
409 409
 
@@ -421,7 +421,7 @@  discard block
 block discarded – undo
421 421
 
422 422
         $suffix .= (in_array($index_name, self::$fields['indexed']) ? 'i' : 'u');
423 423
 
424
-        $index_name .= '_'.$suffix;
424
+        $index_name .= '_' . $suffix;
425 425
 
426 426
         return $index_name;
427 427
 
@@ -444,7 +444,7 @@  discard block
 block discarded – undo
444 444
             $result = $GLOBALS['TYPO3_DB']->exec_SELECTquery(
445 445
                 'tx_dlf_metadata.index_name AS index_name,tx_dlf_metadata.index_tokenized AS index_tokenized,tx_dlf_metadata.index_stored AS index_stored,tx_dlf_metadata.index_indexed AS index_indexed,tx_dlf_metadata.is_sortable AS is_sortable,tx_dlf_metadata.is_facet AS is_facet,tx_dlf_metadata.is_listed AS is_listed,tx_dlf_metadata.index_autocomplete AS index_autocomplete,tx_dlf_metadata.index_boost AS index_boost',
446 446
                 'tx_dlf_metadata',
447
-                'tx_dlf_metadata.pid='.intval($pid).tx_dlf_helper::whereClause('tx_dlf_metadata'),
447
+                'tx_dlf_metadata.pid=' . intval($pid) . tx_dlf_helper::whereClause('tx_dlf_metadata'),
448 448
                 '',
449 449
                 '',
450 450
                 ''
@@ -538,7 +538,7 @@  discard block
 block discarded – undo
538 538
             $solrDoc = $updateQuery->createDocument();
539 539
 
540 540
             // Create unique identifier from document's UID and unit's XML ID.
541
-            $solrDoc->setField('id', $doc->uid.$logicalUnit['id']);
541
+            $solrDoc->setField('id', $doc->uid . $logicalUnit['id']);
542 542
 
543 543
             $solrDoc->setField('uid', $doc->uid);
544 544
 
@@ -585,7 +585,7 @@  discard block
 block discarded – undo
585 585
 
586 586
             $solrDoc->setField('collection', $doc->metadataArray[$doc->toplevelId]['collection']);
587 587
 
588
-            $autocomplete = array ();
588
+            $autocomplete = array();
589 589
 
590 590
             foreach ($metadata as $index_name => $data) {
591 591
 
@@ -596,14 +596,14 @@  discard block
 block discarded – undo
596 596
                     if (in_array($index_name, self::$fields['sortables'])) {
597 597
 
598 598
                         // Add sortable fields to index.
599
-                        $solrDoc->setField($index_name.'_sorting', $metadata[$index_name.'_sorting'][0]);
599
+                        $solrDoc->setField($index_name . '_sorting', $metadata[$index_name . '_sorting'][0]);
600 600
 
601 601
                     }
602 602
 
603 603
                     if (in_array($index_name, self::$fields['facets'])) {
604 604
 
605 605
                         // Add facets to index.
606
-                        $solrDoc->setField($index_name.'_faceting', $data);
606
+                        $solrDoc->setField($index_name . '_faceting', $data);
607 607
 
608 608
                     }
609 609
 
@@ -644,7 +644,7 @@  discard block
 block discarded – undo
644 644
 
645 645
                     $message = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
646 646
                         'TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
647
-                        tx_dlf_helper::getLL('flash.solrException', TRUE).'<br />'.htmlspecialchars($e->getMessage()),
647
+                        tx_dlf_helper::getLL('flash.solrException', TRUE) . '<br />' . htmlspecialchars($e->getMessage()),
648 648
                         tx_dlf_helper::getLL('flash.error', TRUE),
649 649
                         \TYPO3\CMS\Core\Messaging\FlashMessage::ERROR,
650 650
                         TRUE
@@ -748,7 +748,7 @@  discard block
 block discarded – undo
748 748
             $solrDoc = $updateQuery->createDocument();
749 749
 
750 750
             // Create unique identifier from document's UID and unit's XML ID.
751
-            $solrDoc->setField('id', $doc->uid.$physicalUnit['id']);
751
+            $solrDoc->setField('id', $doc->uid . $physicalUnit['id']);
752 752
 
753 753
             $solrDoc->setField('uid', $doc->uid);
754 754
 
@@ -792,7 +792,7 @@  discard block
 block discarded – undo
792 792
                         }
793 793
 
794 794
                         // Add facets to index.
795
-                        $solrDoc->setField($index_name.'_faceting', $data);
795
+                        $solrDoc->setField($index_name . '_faceting', $data);
796 796
 
797 797
                     }
798 798
 
@@ -819,7 +819,7 @@  discard block
 block discarded – undo
819 819
 
820 820
                     $message = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
821 821
                         'TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
822
-                        tx_dlf_helper::getLL('flash.solrException', TRUE).'<br />'.htmlspecialchars($e->getMessage()),
822
+                        tx_dlf_helper::getLL('flash.solrException', TRUE) . '<br />' . htmlspecialchars($e->getMessage()),
823 823
                         tx_dlf_helper::getLL('flash.error', TRUE),
824 824
                         \TYPO3\CMS\Core\Messaging\FlashMessage::ERROR,
825 825
                         TRUE
Please login to merge, or discard this patch.