diff --git a/composer.json b/composer.json index 362d50916cc049ae7b9d0a4d4669d5fe61483368..ef49d0f4378b9d9095f6ccffd8253efa0b5ef0ef 100644 --- a/composer.json +++ b/composer.json @@ -109,7 +109,7 @@ "codeception/module-filesystem": "^3.0.0", "codeception/module-webdriver": "^4.0.0", "composer/composer": "^2.6.5", - "friendsofphp/php-cs-fixer": "^3.35.1", + "friendsofphp/php-cs-fixer": "^3.37.1", "friendsoftypo3/phpstan-typo3": "^0.9.0", "php-webdriver/webdriver": "^1.14.0", "phpstan/phpstan": "^1.10.38", diff --git a/composer.lock b/composer.lock index 6724f08167a941e1008e47cf5ad85668abfe7be2..5aefcb45f9583fe6d23e8f6974da2bdf2c9ece6d 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "c9f4b3374f798540607577d7739e4d98", + "content-hash": "0f0a463411862bb7d727f148e4f09659", "packages": [ { "name": "bacon/bacon-qr-code", @@ -6246,16 +6246,16 @@ }, { "name": "friendsofphp/php-cs-fixer", - "version": "v3.35.1", + "version": "v3.37.1", "source": { "type": "git", "url": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer.git", - "reference": "ec1ccc264994b6764882669973ca435cf05bab08" + "reference": "c3fe76976081ab871aa654e872da588077e19679" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/ec1ccc264994b6764882669973ca435cf05bab08", - "reference": "ec1ccc264994b6764882669973ca435cf05bab08", + "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/c3fe76976081ab871aa654e872da588077e19679", + "reference": "c3fe76976081ab871aa654e872da588077e19679", "shasum": "" }, "require": { @@ -6327,7 +6327,7 @@ ], "support": { "issues": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues", - "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.35.1" + "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.37.1" }, "funding": [ { @@ -6335,7 +6335,7 @@ "type": "github" } ], - "time": "2023-10-12T13:47:26+00:00" + "time": "2023-10-29T20:51:23+00:00" }, { "name": "friendsoftypo3/phpstan-typo3", diff --git a/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php b/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php index a743899697c05620482078fff00d720f62859f6b..e6330e36f0988665d793180afaffca6f9178328c 100644 --- a/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php +++ b/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php @@ -195,7 +195,7 @@ class ElementInformationController // Check if there is a FileRenderer if ($fileRenderer !== null) { $preview['fileRenderer'] = $fileRenderer->render($this->fileObject, $width, $height); - // else check if we can create an Image preview + // else check if we can create an Image preview } elseif ($this->fileObject->isImage()) { $preview['fileObject'] = $this->fileObject; $preview['width'] = $width; diff --git a/typo3/sysext/backend/Classes/Controller/LoginController.php b/typo3/sysext/backend/Classes/Controller/LoginController.php index 5cba3d79fdeef2562d393d7cee976a3433b8c7e6..f19ece81065dbd3c48257eda7238c288b07e58a9 100644 --- a/typo3/sysext/backend/Classes/Controller/LoginController.php +++ b/typo3/sysext/backend/Classes/Controller/LoginController.php @@ -392,7 +392,7 @@ class LoginController if ($this->loginRefresh) { $formProtection->setSessionTokenFromRegistry(); $formProtection->persistSessionToken(); - // triggering `TYPO3/CMS/Backend/LoginRefresh` module happens in `TYPO3/CMS/Backend/Login` + // triggering `TYPO3/CMS/Backend/LoginRefresh` module happens in `TYPO3/CMS/Backend/Login` } else { $formProtection->storeSessionTokenInRegistry(); $this->redirectToUrl(); diff --git a/typo3/sysext/backend/Classes/Form/InlineStackProcessor.php b/typo3/sysext/backend/Classes/Form/InlineStackProcessor.php index 604791577b86733cf2ea0cbc876822af1d7c3ac0..1596a20c1a863b5c9bf45503ca89def3c1cfbaac 100644 --- a/typo3/sysext/backend/Classes/Form/InlineStackProcessor.php +++ b/typo3/sysext/backend/Classes/Form/InlineStackProcessor.php @@ -280,7 +280,7 @@ class InlineStackProcessor $parts[] = implode('][', $levelData['flexform']); } $name = '[' . implode('][', $parts) . ']'; - // Use in object id attributes: + // Use in object id attributes: } else { $name = implode('-', $parts); diff --git a/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php b/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php index 054606d5dd907bf6e364333f3e316ee49c5cc88c..cc56edddbf5bf908143a2b9e8336a8e5f1846e7c 100644 --- a/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php +++ b/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php @@ -540,7 +540,7 @@ abstract class AbstractUserAuthentication implements LoggerAwareInterface if ($ret < 100) { $authenticated = true; } - // $ret is between 100 and 199 which means "I'm not responsible, ask others" + // $ret is between 100 and 199 which means "I'm not responsible, ask others" } else { // $ret is < 0 $authenticated = false; @@ -553,8 +553,8 @@ abstract class AbstractUserAuthentication implements LoggerAwareInterface break; } } - // mimic user authentication to mitigate observable timing discrepancies - // @link https://cwe.mitre.org/data/definitions/208.html + // mimic user authentication to mitigate observable timing discrepancies + // @link https://cwe.mitre.org/data/definitions/208.html } elseif ($activeLogin) { $subType = 'authUser' . $this->loginType; foreach ($this->getAuthServices($subType, $loginData, $authenticatedUserFromSession, $request) as $serviceObj) { diff --git a/typo3/sysext/core/Classes/DataHandling/DataHandler.php b/typo3/sysext/core/Classes/DataHandling/DataHandler.php index 7bfec60e9d81ffbe9fd134c9f8d2c1b9d2702d99..5fdb1d406bb3be9544c3c1cbd69eeea252dd6ced 100644 --- a/typo3/sysext/core/Classes/DataHandling/DataHandler.php +++ b/typo3/sysext/core/Classes/DataHandling/DataHandler.php @@ -4235,7 +4235,7 @@ class DataHandler implements LoggerAwareInterface } else { if (!MathUtility::canBeInterpretedAsInteger($realDestPid)) { $newId = $this->copyRecord($v['table'], $v['id'], -(int)($v['id'])); - // If the destination page id is a NEW string, keep it on the same page + // If the destination page id is a NEW string, keep it on the same page } elseif ($this->BE_USER->workspace > 0 && BackendUtility::isTableWorkspaceEnabled($v['table'])) { // A filled $workspaceOptions indicated that this call // has it's origin in previous versionizeRecord() processing @@ -4249,7 +4249,7 @@ class DataHandler implements LoggerAwareInterface $workspaceOptions['label'] ?? 'Auto-created for WS #' . $this->BE_USER->workspace, $workspaceOptions['delete'] ?? false ); - // Otherwise just use plain copyRecord() to create placeholders etc. + // Otherwise just use plain copyRecord() to create placeholders etc. } else { // If a record has been copied already during this request, // prevent superfluous duplication and use the existing copy @@ -8531,15 +8531,15 @@ class DataHandler implements LoggerAwareInterface default: $result = (string)$submittedValue === (string)$storedValue; } - // Null values are allowed, but currently there's a real (not NULL) value. - // Thus, ensure no NULL value was submitted and fallback to the regular behaviour. + // Null values are allowed, but currently there's a real (not NULL) value. + // Thus, ensure no NULL value was submitted and fallback to the regular behaviour. } elseif ($storedValue !== null) { $result = ( $submittedValue !== null && $this->isSubmittedValueEqualToStoredValue($submittedValue, $storedValue, $storedType, false) ); - // Null values are allowed, and currently there's a NULL value. - // Thus, check whether a NULL value was submitted. + // Null values are allowed, and currently there's a NULL value. + // Thus, check whether a NULL value was submitted. } else { $result = ($submittedValue === null); } diff --git a/typo3/sysext/core/Classes/DataHandling/Localization/DataMapProcessor.php b/typo3/sysext/core/Classes/DataHandling/Localization/DataMapProcessor.php index 0b275df5730cf8a1ffa0eb2117a07915a9a9655d..cce37df8cdd5e2d53a799d4d5bbf90fe6bc52d22 100644 --- a/typo3/sysext/core/Classes/DataHandling/Localization/DataMapProcessor.php +++ b/typo3/sysext/core/Classes/DataHandling/Localization/DataMapProcessor.php @@ -1026,7 +1026,7 @@ class DataMapProcessor // implicit: use origin pointer if table cannot be translated if (!$isTranslatable) { $ancestorId = (int)$dependentElement[$fieldNames['origin']]; - // only consider element if it reflects the desired language + // only consider element if it reflects the desired language } elseif ((int)$dependentElement[$fieldNames['language']] === $desiredLanguage) { $ancestorId = $this->resolveAncestorId($fieldNames, $dependentElement); } else { diff --git a/typo3/sysext/core/Classes/Database/Driver/DriverStatement.php b/typo3/sysext/core/Classes/Database/Driver/DriverStatement.php index 3657bd2f9b4d25aea55b66a4053f023fe6cface9..90ab5de8ced6cfa6796c9ef50efa20ea6bd24ffb 100644 --- a/typo3/sysext/core/Classes/Database/Driver/DriverStatement.php +++ b/typo3/sysext/core/Classes/Database/Driver/DriverStatement.php @@ -131,7 +131,7 @@ class DriverStatement implements StatementInterface */ private function convertParamType(int $type): int { - if (! isset(self::PARAM_TYPE_MAP[$type])) { + if (!isset(self::PARAM_TYPE_MAP[$type])) { throw UnknownParameterType::new($type); } diff --git a/typo3/sysext/core/Classes/Database/Driver/PDOMySql/Driver.php b/typo3/sysext/core/Classes/Database/Driver/PDOMySql/Driver.php index 350f22f5c8937e0671cb1eaa35ae476496bd32a4..97e2691fe6884447f83589d7c07a4188e35ea8ee 100644 --- a/typo3/sysext/core/Classes/Database/Driver/PDOMySql/Driver.php +++ b/typo3/sysext/core/Classes/Database/Driver/PDOMySql/Driver.php @@ -41,7 +41,7 @@ class Driver extends AbstractMySQLDriver { $driverOptions = $params['driverOptions'] ?? []; - if (! empty($params['persistent'])) { + if (!empty($params['persistent'])) { $driverOptions[\PDO::ATTR_PERSISTENT] = true; } diff --git a/typo3/sysext/core/Classes/Database/Driver/PDOPgSql/Driver.php b/typo3/sysext/core/Classes/Database/Driver/PDOPgSql/Driver.php index dd8668ce5273356086df84d6fb059cc50346d16a..3f1f3767b647a364846da0a75d2c4befd7ac0c30 100644 --- a/typo3/sysext/core/Classes/Database/Driver/PDOPgSql/Driver.php +++ b/typo3/sysext/core/Classes/Database/Driver/PDOPgSql/Driver.php @@ -39,7 +39,7 @@ class Driver extends AbstractPostgreSQLDriver { $driverOptions = $params['driverOptions'] ?? []; - if (! empty($params['persistent'])) { + if (!empty($params['persistent'])) { $driverOptions[\PDO::ATTR_PERSISTENT] = true; } @@ -53,7 +53,7 @@ class Driver extends AbstractPostgreSQLDriver if (defined('PDO::PGSQL_ATTR_DISABLE_PREPARES') && ( - ! isset($driverOptions[\PDO::PGSQL_ATTR_DISABLE_PREPARES]) + !isset($driverOptions[\PDO::PGSQL_ATTR_DISABLE_PREPARES]) || $driverOptions[\PDO::PGSQL_ATTR_DISABLE_PREPARES] === true ) ) { diff --git a/typo3/sysext/core/Classes/Database/Schema/Comparator.php b/typo3/sysext/core/Classes/Database/Schema/Comparator.php index 14b681ce93acf19a192da25769ccef740075d2ac..8b212ae17ff7e3ab540dd8f559b8700f0f88f481 100644 --- a/typo3/sysext/core/Classes/Database/Schema/Comparator.php +++ b/typo3/sysext/core/Classes/Database/Schema/Comparator.php @@ -179,7 +179,7 @@ class Comparator extends \Doctrine\DBAL\Schema\Comparator foreach ($toSchema->getTables() as $table) { $tableName = $table->getShortestName($toSchema->getName()); - if (! $fromSchema->hasTable($tableName)) { + if (!$fromSchema->hasTable($tableName)) { $diff->newTables[$tableName] = $toSchema->getTable($tableName); } else { $tableDifferences = $comparator->diffTable( @@ -198,14 +198,14 @@ class Comparator extends \Doctrine\DBAL\Schema\Comparator $tableName = $table->getShortestName($fromSchema->getName()); $table = $fromSchema->getTable($tableName); - if (! $toSchema->hasTable($tableName)) { + if (!$toSchema->hasTable($tableName)) { $diff->removedTables[$tableName] = $table; } // also remember all foreign keys that point to a specific table foreach ($table->getForeignKeys() as $foreignKey) { $foreignTable = strtolower($foreignKey->getForeignTableName()); - if (! isset($foreignKeysToTable[$foreignTable])) { + if (!isset($foreignKeysToTable[$foreignTable])) { $foreignKeysToTable[$foreignTable] = []; } @@ -214,7 +214,7 @@ class Comparator extends \Doctrine\DBAL\Schema\Comparator } foreach ($diff->removedTables as $tableName => $table) { - if (! isset($foreignKeysToTable[$tableName])) { + if (!isset($foreignKeysToTable[$tableName])) { continue; } @@ -225,7 +225,7 @@ class Comparator extends \Doctrine\DBAL\Schema\Comparator foreach ($foreignKeysToTable[$tableName] as $foreignKey) { // strtolower the table name to make if compatible with getShortestName $localTableName = strtolower($foreignKey->getLocalTableName()); - if (! isset($diff->changedTables[$localTableName])) { + if (!isset($diff->changedTables[$localTableName])) { continue; } @@ -244,8 +244,8 @@ class Comparator extends \Doctrine\DBAL\Schema\Comparator foreach ($toSchema->getSequences() as $sequence) { $sequenceName = $sequence->getShortestName($toSchema->getName()); - if (! $fromSchema->hasSequence($sequenceName)) { - if (! $comparator->isAutoIncrementSequenceInSchema($fromSchema, $sequence)) { + if (!$fromSchema->hasSequence($sequenceName)) { + if (!$comparator->isAutoIncrementSequenceInSchema($fromSchema, $sequence)) { $diff->newSequences[] = $sequence; } } else { diff --git a/typo3/sysext/core/Classes/Html/SimpleParser.php b/typo3/sysext/core/Classes/Html/SimpleParser.php index b2bab6b1d950beadb09c673fc883338a3d20aa70..7c9528cfa2117fb4e59b2cc08dd7a6b79f121001 100644 --- a/typo3/sysext/core/Classes/Html/SimpleParser.php +++ b/typo3/sysext/core/Classes/Html/SimpleParser.php @@ -128,53 +128,53 @@ class SimpleParser $this->next(SimpleNode::TYPE_CDATA); $this->append('<![CDATA['); $skip = 8; - // comment start + // comment start } elseif ($character === '<' && $this->isType(SimpleNode::TYPE_TEXT) && substr($string, $i, 4) === '<!--' ) { $this->next(SimpleNode::TYPE_COMMENT); $this->append('<!--'); $skip = 3; - // element start + // element start } elseif ($character === '<' && $this->isType(SimpleNode::TYPE_TEXT) && preg_match('#^</?[a-z]#i', substr($string, $i, 3)) ) { $this->next(SimpleNode::TYPE_ELEMENT); $this->append($character); - // CDATA end + // CDATA end } elseif ($character === ']' && $this->isType(SimpleNode::TYPE_CDATA) && substr($string, $i, 3) === ']]>' ) { $this->append(']]>'); $this->next(SimpleNode::TYPE_TEXT); $skip = 2; - // comment end + // comment end } elseif ($character === '-' && $this->isType(SimpleNode::TYPE_COMMENT) && substr($string, $i, 3) === '-->' ) { $this->append('-->'); $this->next(SimpleNode::TYPE_TEXT); $skip = 2; - // element end + // element end } elseif ($character === '>' && $this->isType(SimpleNode::TYPE_ELEMENT) && !$this->inAttribute() ) { $this->append($character); $this->next(SimpleNode::TYPE_TEXT); - // element attribute start + // element attribute start } elseif (($character === '"' || $character === "'") && $this->isType(SimpleNode::TYPE_ELEMENT) && !$this->inAttribute() ) { $this->attribute = $character; $this->append($character); - // element attribute end + // element attribute end } elseif (($character === '"' || $character === "'") && $this->isType(SimpleNode::TYPE_ELEMENT) && $this->attribute === $character ) { $this->append($character); $this->attribute = null; - // anything else (put to current type) + // anything else (put to current type) } else { $this->append($character); } diff --git a/typo3/sysext/core/Classes/LinkHandling/LegacyLinkNotationConverter.php b/typo3/sysext/core/Classes/LinkHandling/LegacyLinkNotationConverter.php index 889b484a297c5f514fcae36d194494c23744e87b..9ac39b3bca5d2a204d97f5fcb05cb47ff1d5acb7 100644 --- a/typo3/sysext/core/Classes/LinkHandling/LegacyLinkNotationConverter.php +++ b/typo3/sysext/core/Classes/LinkHandling/LegacyLinkNotationConverter.php @@ -145,7 +145,7 @@ class LegacyLinkNotationConverter if (!$isIdOrAlias && $isLocalFile !== 1 && $urlChar && (!$containsSlash || $urlChar < $fileChar)) { $result['type'] = LinkService::TYPE_URL; $result['url'] = UrlLinkHandler::getDefaultScheme() . '://' . $linkParameter; - // file (internal) or folder + // file (internal) or folder } elseif ($containsSlash || $isLocalFile) { $result = $this->getFileOrFolderObjectFromMixedIdentifier($linkParameter); } else { diff --git a/typo3/sysext/core/Classes/Resource/Driver/LocalDriver.php b/typo3/sysext/core/Classes/Resource/Driver/LocalDriver.php index a5a30483ba8667d252a29aeb61f04cc2db9848ba..c01d7f1e3e5fab845fae1b922b2828de6bfb5bac 100644 --- a/typo3/sysext/core/Classes/Resource/Driver/LocalDriver.php +++ b/typo3/sysext/core/Classes/Resource/Driver/LocalDriver.php @@ -372,7 +372,7 @@ class LocalDriver extends AbstractHierarchicalFilesystemDriver implements Stream } // $c is the counter for how many items we still have to fetch (-1 is unlimited) - $c = $numberOfItems > 0 ? $numberOfItems : - 1; + $c = $numberOfItems > 0 ? $numberOfItems : -1; $items = []; while ($iterator->valid() && ($numberOfItems === 0 || $c > 0)) { // $iteratorItem is the file or folder name diff --git a/typo3/sysext/core/Classes/Routing/Aspect/PersistedPatternMapper.php b/typo3/sysext/core/Classes/Routing/Aspect/PersistedPatternMapper.php index 054680cca5707e578d981b1b259c2d11cd0bc19c..040c2ac2d63f5b280ea8aa8643d97b438c09b159 100644 --- a/typo3/sysext/core/Classes/Routing/Aspect/PersistedPatternMapper.php +++ b/typo3/sysext/core/Classes/Routing/Aspect/PersistedPatternMapper.php @@ -285,7 +285,7 @@ class PersistedPatternMapper implements PersistedMappableAspectInterface, Static $queryBuilder->expr()->eq('uid', $idParameter), $queryBuilder->expr()->eq($this->languageParentFieldName, $idParameter) ); - // otherwise - basically uid is not in pattern - restrict to languages and apply fallbacks + // otherwise - basically uid is not in pattern - restrict to languages and apply fallbacks } elseif ($languageAware) { $languageIds = $this->resolveAllRelevantLanguageIds(); $constraints[] = $queryBuilder->expr()->in( diff --git a/typo3/sysext/core/Classes/Security/ContentSecurityPolicy/PolicyProvider.php b/typo3/sysext/core/Classes/Security/ContentSecurityPolicy/PolicyProvider.php index a72a459cb18afc92e7b7a95807bce0389ac37ab1..446f2b4890f66b14cfb5199a123b9df0cfb74ab0 100644 --- a/typo3/sysext/core/Classes/Security/ContentSecurityPolicy/PolicyProvider.php +++ b/typo3/sysext/core/Classes/Security/ContentSecurityPolicy/PolicyProvider.php @@ -98,7 +98,7 @@ final class PolicyProvider $siteLanguage = $siteLanguage instanceof SiteLanguage ? $siteLanguage : $site->getDefaultLanguage(); $uri = $siteLanguage->getBase(); $uri = $uri->withPath(rtrim($uri->getPath(), '/') . '/'); - // otherwise fall back to current request URI + // otherwise fall back to current request URI } else { $uri = new Uri($normalizedParams->getSitePath()); } diff --git a/typo3/sysext/core/Classes/TypoScript/AST/CurrentObjectPath/CurrentObjectPathStack.php b/typo3/sysext/core/Classes/TypoScript/AST/CurrentObjectPath/CurrentObjectPathStack.php index a2486aab6b4c7cb071d5cc8ece76ae0447b3a0c6..537ddc174ba6e1989ffa7702b75c0b42b8903da1 100644 --- a/typo3/sysext/core/Classes/TypoScript/AST/CurrentObjectPath/CurrentObjectPathStack.php +++ b/typo3/sysext/core/Classes/TypoScript/AST/CurrentObjectPath/CurrentObjectPathStack.php @@ -35,7 +35,7 @@ final class CurrentObjectPathStack public function push(CurrentObjectPath $path): void { $this->stack[] = $path; - $this->stackSize ++; + $this->stackSize++; } public function pop(): CurrentObjectPath @@ -47,7 +47,7 @@ final class CurrentObjectPathStack return $this->getCurrent(); } array_pop($this->stack); - $this->stackSize --; + $this->stackSize--; return $this->getCurrent(); } diff --git a/typo3/sysext/core/Classes/TypoScript/AST/Node/AbstractNode.php b/typo3/sysext/core/Classes/TypoScript/AST/Node/AbstractNode.php index 1e5a51949c7c145eeb4fc33cc12838ced9d3b584..17d3274a2ccf6fe74fbf0eb0d334c14f983188a7 100644 --- a/typo3/sysext/core/Classes/TypoScript/AST/Node/AbstractNode.php +++ b/typo3/sysext/core/Classes/TypoScript/AST/Node/AbstractNode.php @@ -67,7 +67,7 @@ abstract class AbstractNode implements NodeInterface $childCounter = 0; foreach ($this->getNextChild() as $child) { $child->setIdentifier($this->identifier . $childCounter); - $childCounter ++; + $childCounter++; } } diff --git a/typo3/sysext/core/Classes/TypoScript/AST/Visitor/AstConstantCommentVisitor.php b/typo3/sysext/core/Classes/TypoScript/AST/Visitor/AstConstantCommentVisitor.php index dcab17e99c97aaa68e5244334cf2a08f3f73a4a7..23f84d438010916fdc0d274dbb7e92505c33e29a 100644 --- a/typo3/sysext/core/Classes/TypoScript/AST/Visitor/AstConstantCommentVisitor.php +++ b/typo3/sysext/core/Classes/TypoScript/AST/Visitor/AstConstantCommentVisitor.php @@ -386,7 +386,7 @@ final class AstConstantCommentVisitor implements AstVisitorInterface return []; } if (isset($this->categories[$mainCategory])) { - $this->categories[$mainCategory]['usageCount'] ++; + $this->categories[$mainCategory]['usageCount']++; } else { $this->categories[$mainCategory] = [ 'usageCount' => 1, diff --git a/typo3/sysext/core/Classes/TypoScript/IncludeTree/Visitor/IncludeTreeSyntaxScannerVisitor.php b/typo3/sysext/core/Classes/TypoScript/IncludeTree/Visitor/IncludeTreeSyntaxScannerVisitor.php index 3fb15328d74f6cb2edf7b199248553e23288fd77..bb5bd448fe806ce858fd36d38b95f4857497a63e 100644 --- a/typo3/sysext/core/Classes/TypoScript/IncludeTree/Visitor/IncludeTreeSyntaxScannerVisitor.php +++ b/typo3/sysext/core/Classes/TypoScript/IncludeTree/Visitor/IncludeTreeSyntaxScannerVisitor.php @@ -97,10 +97,10 @@ final class IncludeTreeSyntaxScannerVisitor implements IncludeTreeVisitorInterfa ]; } if ($line instanceof IdentifierBlockOpenLine) { - $braceCount ++; + $braceCount++; } if ($line instanceof BlockCloseLine) { - $braceCount --; + $braceCount--; if ($braceCount < 0) { $braceCount = 0; $this->errors[] = [ diff --git a/typo3/sysext/core/Classes/TypoScript/Tokenizer/Line/LineStream.php b/typo3/sysext/core/Classes/TypoScript/Tokenizer/Line/LineStream.php index 226130781091ffd6ed8cbd8c9455e764d0832552..8431411d9f1c83c54cabda11d4792a972d0989a5 100644 --- a/typo3/sysext/core/Classes/TypoScript/Tokenizer/Line/LineStream.php +++ b/typo3/sysext/core/Classes/TypoScript/Tokenizer/Line/LineStream.php @@ -110,7 +110,7 @@ final class LineStream */ public function getNext(): ?LineInterface { - $this->currentIndex ++; + $this->currentIndex++; return $this->lines[$this->currentIndex] ?? null; } diff --git a/typo3/sysext/core/Classes/TypoScript/Tokenizer/LosslessTokenizer.php b/typo3/sysext/core/Classes/TypoScript/Tokenizer/LosslessTokenizer.php index b575df24edba03c20e814230f616432a5415fba2..d6e157bdfdcad49e3b992956be2a33eb3ee3361d 100644 --- a/typo3/sysext/core/Classes/TypoScript/Tokenizer/LosslessTokenizer.php +++ b/typo3/sysext/core/Classes/TypoScript/Tokenizer/LosslessTokenizer.php @@ -324,7 +324,7 @@ final class LosslessTokenizer implements TokenizerInterface private function createBlockStopLine(): void { $this->tokenStream->append(new Token(TokenType::T_BLOCK_STOP, $this->currentLineString, $this->currentLineNumber, $this->currentColumnInLine)); - $this->currentColumnInLine ++; + $this->currentColumnInLine++; $this->currentLineString = substr($this->currentLineString, 1); $this->makeComment(); $this->lineStream->append((new BlockCloseLine())->setTokenStream($this->tokenStream)); @@ -333,7 +333,7 @@ final class LosslessTokenizer implements TokenizerInterface private function parseBlockStart(): void { $this->tokenStream->append(new Token(TokenType::T_BLOCK_START, '{', $this->currentLineNumber, $this->currentColumnInLine)); - $this->currentColumnInLine ++; + $this->currentColumnInLine++; $this->currentLineString = substr($this->currentLineString, 1); $this->parseTabsAndWhitespaces(); if (str_starts_with($this->currentLineString, '}')) { @@ -531,7 +531,7 @@ final class LosslessTokenizer implements TokenizerInterface private function parseOperatorAssignment(): void { $this->tokenStream->append(new Token(TokenType::T_OPERATOR_ASSIGNMENT, '=', $this->currentLineNumber, $this->currentColumnInLine)); - $this->currentColumnInLine ++; + $this->currentColumnInLine++; $this->currentLineString = substr($this->currentLineString, 1); $this->parseTabsAndWhitespaces(); $this->valueStream = new TokenStream(); @@ -544,7 +544,7 @@ final class LosslessTokenizer implements TokenizerInterface { $this->valueStream = new TokenStream(); $this->tokenStream->append(new Token(TokenType::T_OPERATOR_ASSIGNMENT_MULTILINE_START, '(', $this->currentLineNumber, $this->currentColumnInLine)); - $this->currentColumnInLine ++; + $this->currentColumnInLine++; $this->currentLineString = substr($this->currentLineString, 1); // True if we're currently in the line with the opening '(' $isFirstLine = true; @@ -627,7 +627,7 @@ final class LosslessTokenizer implements TokenizerInterface private function parseOperatorUnset(): void { $this->tokenStream->append(new Token(TokenType::T_OPERATOR_UNSET, '>', $this->currentLineNumber, $this->currentColumnInLine)); - $this->currentColumnInLine ++; + $this->currentColumnInLine++; $this->currentLineString = substr($this->currentLineString, 1); $this->parseTabsAndWhitespaces(); $this->makeComment(); @@ -637,7 +637,7 @@ final class LosslessTokenizer implements TokenizerInterface private function parseOperatorCopy(): void { $this->tokenStream->append(new Token(TokenType::T_OPERATOR_COPY, '<', $this->currentLineNumber, $this->currentColumnInLine)); - $this->currentColumnInLine ++; + $this->currentColumnInLine++; $this->currentLineString = substr($this->currentLineString, 1); $this->parseTabsAndWhitespaces(); $identifierStream = $this->identifierStream; diff --git a/typo3/sysext/core/Classes/TypoScript/Tokenizer/Token/AbstractTokenStream.php b/typo3/sysext/core/Classes/TypoScript/Tokenizer/Token/AbstractTokenStream.php index c19651cf32040913d547694b6687bf6ceda4a2b7..38d50df104debf5315db0a65b51a9a24e4d7f1b1 100644 --- a/typo3/sysext/core/Classes/TypoScript/Tokenizer/Token/AbstractTokenStream.php +++ b/typo3/sysext/core/Classes/TypoScript/Tokenizer/Token/AbstractTokenStream.php @@ -91,7 +91,7 @@ abstract class AbstractTokenStream implements TokenStreamInterface */ public function getNext(): ?TokenInterface { - $this->currentIndex ++; + $this->currentIndex++; return $this->tokens[$this->currentIndex] ?? null; } diff --git a/typo3/sysext/extbase/Classes/Persistence/Generic/Storage/Typo3DbBackend.php b/typo3/sysext/extbase/Classes/Persistence/Generic/Storage/Typo3DbBackend.php index 96944057d2612b747163fabfb6d5c5207b85226b..64c1aeb50a86a06d5ba0cfabf44414ec09cd4367 100644 --- a/typo3/sysext/extbase/Classes/Persistence/Generic/Storage/Typo3DbBackend.php +++ b/typo3/sysext/extbase/Classes/Persistence/Generic/Storage/Typo3DbBackend.php @@ -251,7 +251,7 @@ class Typo3DbBackend implements BackendInterface, SingletonInterface throw new SqlErrorException($e->getPrevious()->getMessage(), 1472064721, $e); } $rows = $result->fetchAllAssociative(); - // Prepared Doctrine DBAL statement + // Prepared Doctrine DBAL statement } elseif ($realStatement instanceof \Doctrine\DBAL\Statement) { try { $result = $realStatement->executeQuery($parameters); diff --git a/typo3/sysext/extbase/Classes/Routing/ExtbasePluginEnhancer.php b/typo3/sysext/extbase/Classes/Routing/ExtbasePluginEnhancer.php index ca7cfc38dd4d36c834b13390086bdb888f4413c1..72d793cc8451d34d04b3711d61c319736e896bf6 100644 --- a/typo3/sysext/extbase/Classes/Routing/ExtbasePluginEnhancer.php +++ b/typo3/sysext/extbase/Classes/Routing/ExtbasePluginEnhancer.php @@ -230,10 +230,10 @@ class ExtbasePluginEnhancer extends PluginEnhancer // use default action name if controller matches if ($tryUpdate && empty($target['action']) && $controllerName === ($target['controller'] ?? null)) { $target['action'] = $actionName; - // use default controller name if action is defined (implies: non-default-controllers must be given) + // use default controller name if action is defined (implies: non-default-controllers must be given) } elseif ($tryUpdate && empty($target['controller']) && !empty($target['action'])) { $target['controller'] = $controllerName; - // fallback and override + // fallback and override } else { $target['controller'] = $controllerName; $target['action'] = $actionName; diff --git a/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php b/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php index c943eb902d8d1fc67f38b42813927849736cb783..f1837b32a542f04b1606fd800b4bb6bab6b32aaf 100644 --- a/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php +++ b/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php @@ -468,7 +468,7 @@ class FormViewHelper extends AbstractFormViewHelper // basically "request token, yes" - uses form-action URI as scope if ($isTrulyRequestToken || $requestToken === '@nonce') { $requestToken = RequestToken::create($formAction); - // basically "request token with 'my-scope'" - uses 'my-scope' + // basically "request token with 'my-scope'" - uses 'my-scope' } elseif (is_string($requestToken) && $requestToken !== '') { $requestToken = RequestToken::create($requestToken); } diff --git a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php index 55f91cb0383372abeafe8a98eceb1a8f2d0bd119..b5a37b1ece655d2577ceeaafba27b09362af18ef 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php +++ b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php @@ -4367,7 +4367,7 @@ class ContentObjectRenderer implements LoggerAwareInterface if (method_exists($value, 'get' . ucfirst($currentKey))) { $getterMethod = 'get' . ucfirst($currentKey); $value = $value->$getterMethod(...)(); - // server request attribute, such as "routing" + // server request attribute, such as "routing" } elseif ($value instanceof ServerRequestInterface) { $value = $value->getAttribute($currentKey); } else { diff --git a/typo3/sysext/frontend/Classes/DataProcessing/GalleryProcessor.php b/typo3/sysext/frontend/Classes/DataProcessing/GalleryProcessor.php index 8510254d6f2c2d7a8096146d370af136d7dd3d2b..03a43279731153c515f3d6cb962d6780a194a81d 100644 --- a/typo3/sysext/frontend/Classes/DataProcessing/GalleryProcessor.php +++ b/typo3/sysext/frontend/Classes/DataProcessing/GalleryProcessor.php @@ -422,7 +422,7 @@ class GalleryProcessor implements DataProcessorInterface // Recalculate gallery width $this->galleryData['width'] = floor($maximumRowWidth / $mediaScalingCorrection); - // User entered a predefined width + // User entered a predefined width } elseif ($this->equalMediaWidth) { $mediaScalingCorrection = 1; @@ -446,7 +446,7 @@ class GalleryProcessor implements DataProcessorInterface // Recalculate gallery width $this->galleryData['width'] = floor($totalRowWidth / $mediaScalingCorrection); - // Automatic setting of width and height + // Automatic setting of width and height } else { $maxMediaWidth = (int)($galleryWidthMinusBorderAndSpacing / $this->galleryData['count']['columns']); foreach ($this->fileObjects as $key => $fileObject) { diff --git a/typo3/sysext/frontend/Classes/Middleware/PageArgumentValidator.php b/typo3/sysext/frontend/Classes/Middleware/PageArgumentValidator.php index 3c9249932bc11e71e908a98f7f80343525040b56..3d2b91b3b63415600cd9b9dcd7afb8ba37a8e313 100644 --- a/typo3/sysext/frontend/Classes/Middleware/PageArgumentValidator.php +++ b/typo3/sysext/frontend/Classes/Middleware/PageArgumentValidator.php @@ -99,7 +99,7 @@ class PageArgumentValidator implements MiddlewareInterface, LoggerAwareInterface ['code' => PageAccessFailureReasons::CACHEHASH_COMPARISON_FAILED] ); } - // No cHash given but was required + // No cHash given but was required } elseif (!$this->evaluatePageArgumentsWithoutCacheHash($pageArguments, $pageNotFoundOnValidationError)) { return GeneralUtility::makeInstance(ErrorController::class)->pageNotFoundAction( $request, diff --git a/typo3/sysext/indexed_search/Tests/Functional/Utility/LikeWildcardTest.php b/typo3/sysext/indexed_search/Tests/Functional/Utility/LikeWildcardTest.php index db6e23dbd705f4b5b25893fafcf26a34c391d8e9..3cc3d213db32e35264f5f102eac16621c9fb5f7e 100644 --- a/typo3/sysext/indexed_search/Tests/Functional/Utility/LikeWildcardTest.php +++ b/typo3/sysext/indexed_search/Tests/Functional/Utility/LikeWildcardTest.php @@ -42,7 +42,7 @@ final class LikeWildcardTest extends FunctionalTestCase $expected = addcslashes($expected, '\\'); } $expected = $connection->quoteIdentifier($fieldName) . ' ' . $expected; - if (! $connection->getDatabasePlatform() instanceof PostgreSQLPlatform) { + if (!$connection->getDatabasePlatform() instanceof PostgreSQLPlatform) { $expected .= ' ESCAPE ' . $connection->quote('\\'); } self::assertSame($expected, $subject->getLikeQueryPart($tableName, $fieldName, $likeValue)); diff --git a/typo3/sysext/lowlevel/Classes/Command/MissingRelationsCommand.php b/typo3/sysext/lowlevel/Classes/Command/MissingRelationsCommand.php index 7efe7983dba68d11dcbb84111d29263b6b8f316c..02ed7f305622f5f7b3aa6a1d34841588c6b35c86 100644 --- a/typo3/sysext/lowlevel/Classes/Command/MissingRelationsCommand.php +++ b/typo3/sysext/lowlevel/Classes/Command/MissingRelationsCommand.php @@ -279,7 +279,7 @@ If you want to get more detailed information, use the --verbose option.') } else { $offlineVersionRecords[$idx][$rec['hash']] = $infoString; } - // reference to a deleted record + // reference to a deleted record } elseif (isset($GLOBALS['TCA'][$rec['ref_table']]['ctrl']['delete']) && $existingRecords[$idx][$GLOBALS['TCA'][$rec['ref_table']]['ctrl']['delete']]) { if ($isSoftReference) { $deletedRecordsInSoftReferenceRelations[] = $infoString;