Commit 1ac8bbdc authored by Nikita Hovratov's avatar Nikita Hovratov Committed by Christian Kuhn
Browse files

[TASK] Remove redundant @var tags

The type can already be inferred from the source
code.

The cleanup was run automatically with a
PHPStorm plugin.

Resolves: #96482
Releases: main
Change-Id: I669145adc66dc898f3016de1958cf0105c988243
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/72907


Tested-by: core-ci's avatarcore-ci <typo3@b13.com>
Tested-by: Benjamin Franzke's avatarBenjamin Franzke <bfr@qbus.de>
Tested-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Benjamin Franzke's avatarBenjamin Franzke <bfr@qbus.de>
Reviewed-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
parent 84f22765
......@@ -246,7 +246,6 @@ class RequestTest extends UnitTestCase
*/
public function setControllerObjectNameResolvesControllerObjectNameArgumentsCorrectly($controllerArguments, $controllerObjectName): void
{
/** @var $request \TYPO3\CMS\Extbase\Mvc\Request */
$request = new Request();
$request->setControllerObjectName($controllerObjectName);
......
......@@ -140,7 +140,6 @@ class ExtensionStatus implements StatusProviderInterface
array_key_exists('terObject', $information)
&& $information['terObject'] instanceof Extension
) {
/** @var \TYPO3\CMS\Extensionmanager\Domain\Model\Extension $terObject */
$terObject = $information['terObject'];
$insecureStatus = $terObject->getReviewState();
if ($insecureStatus === -1) {
......
......@@ -34,7 +34,6 @@ use TYPO3\CMS\Core\Package\PackageManager;
use TYPO3\CMS\Core\Registry;
use TYPO3\CMS\Core\Service\OpcodeCacheService;
use TYPO3\CMS\Core\SingletonInterface;
use TYPO3\CMS\Core\Site\Entity\Site;
use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Core\Utility\PathUtility;
......@@ -573,7 +572,6 @@ class InstallUtility implements SingletonInterface, LoggerAwareInterface
}
}
/** @var Site[] $newSites */
$newSites = array_diff_key($siteConfiguration->resolveAllExistingSites(false), $existingSites);
$importedPages = [];
if ($import instanceof Import) {
......
......@@ -190,7 +190,6 @@ class GifBuilder extends GraphicalFunctions
$this->setup[$theKey . '.']['file'] = $fileInfo['processedFile']->getForLocalProcessing(false);
} elseif (!isset($fileInfo['origFile']) && $fileInfo['originalFile'] instanceof File) {
// Use FAL file with getForLocalProcessing to circumvent problems with umlauts, if it is a FAL file (origFile not set)
/** @var File $originalFile */
$originalFile = $fileInfo['originalFile'];
$this->setup[$theKey . '.']['file'] = $originalFile->getForLocalProcessing(false);
} else {
......@@ -213,7 +212,6 @@ class GifBuilder extends GraphicalFunctions
if (($maskInfo['processedFile'] ?? null) instanceof ProcessedFile) {
$this->setup[$theKey . '.']['mask'] = $maskInfo['processedFile']->getForLocalProcessing(false);
} elseif (!isset($maskInfo['origFile']) && $maskInfo['originalFile'] instanceof File) {
/** @var File $originalFile */
$originalFile = $maskInfo['originalFile'];
$this->setup[$theKey . '.']['mask'] = $originalFile->getForLocalProcessing(false);
} else {
......
......@@ -456,7 +456,6 @@ class InfoModuleController
$languageService->getLL('title'),
FlashMessage::ERROR
);
/** @var \TYPO3\CMS\Core\Messaging\FlashMessageQueue $defaultFlashMessageQueue */
$defaultFlashMessageQueue = $this->flashMessageService->getMessageQueueByIdentifier();
$defaultFlashMessageQueue->enqueue($flashMessage);
} else {
......
......@@ -76,7 +76,6 @@ class FeatureManager
$localConfigurationValuesToSet = [];
$features = $this->getInitializedFeatures($postValues);
foreach ($features as $feature) {
/** @var FeatureInterface $feature */
$featureName = $feature->getName();
$presets = $feature->getPresetsOrderedByPriority();
foreach ($presets as $preset) {
......@@ -107,7 +106,6 @@ class FeatureManager
$localConfigurationValuesToSet = [];
$features = $this->getInitializedFeatures([]);
foreach ($features as $feature) {
/** @var FeatureInterface $feature */
$presets = $feature->getPresetsOrderedByPriority();
foreach ($presets as $preset) {
// Only choose "normal" presets, no custom presets
......
......@@ -25,7 +25,6 @@ use Symfony\Component\Console\Style\SymfonyStyle;
use TYPO3\CMS\Backend\Utility\BackendUtility;
use TYPO3\CMS\Core\Core\Bootstrap;
use TYPO3\CMS\Core\Database\ConnectionPool;
use TYPO3\CMS\Core\Database\Query\QueryBuilder;
use TYPO3\CMS\Core\DataHandling\DataHandler;
use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Core\Utility\MathUtility;
......@@ -143,7 +142,6 @@ class DeletedRecordsCommand extends Command
*/
protected function findAllFlaggedRecordsInPage(int $pageId, int $depth, array $deletedRecords = []): array
{
/** @var QueryBuilder $queryBuilderForPages */
$queryBuilderForPages = $this->connectionPool
->getQueryBuilderForTable('pages');
$queryBuilderForPages->getRestrictions()->removeAll();
......
......@@ -127,7 +127,6 @@ class FileBrowser extends AbstractElementBrowser implements ElementBrowserInterf
$filterObject->setAllowedFileExtensions($allowedFileExtensions);
// Set file extension filters on all storages
$storages = $backendUser->getFileStorages();
/** @var \TYPO3\CMS\Core\Resource\ResourceStorage $storage */
foreach ($storages as $storage) {
$storage->addFileAndFolderNameFilter([$filterObject, 'filterFileList']);
}
......
......@@ -292,7 +292,6 @@ class RecordListController
unset($ll);
/** @var \TYPO3\CMS\Core\Messaging\FlashMessageService $flashMessageService */
$flashMessageService = GeneralUtility::makeInstance(FlashMessageService::class);
/** @var \TYPO3\CMS\Core\Messaging\FlashMessageQueue $defaultFlashMessageQueue */
$defaultFlashMessageQueue = $flashMessageService->getMessageQueueByIdentifier();
$defaultFlashMessageQueue->enqueue($flashMessage);
}
......
......@@ -59,7 +59,6 @@ class FalStatus implements StatusProviderInterface
$storageObjects = $storageRepository->findAll();
$storages = [];
/** @var \TYPO3\CMS\Core\Resource\ResourceStorage $storageObject */
foreach ($storageObjects as $storageObject) {
// We only check missing files for storages that are online
......
......@@ -70,7 +70,6 @@ class BackendUtilityHook
$flashMessage = GeneralUtility::makeInstance(FlashMessage::class, sprintf($message, $stageName, $editingName), '', FlashMessage::INFO, true);
/** @var FlashMessageService $flashMessageService */
$flashMessageService = GeneralUtility::makeInstance(FlashMessageService::class);
/** @var \TYPO3\CMS\Core\Messaging\FlashMessageQueue $defaultFlashMessageQueue */
$defaultFlashMessageQueue = $flashMessageService->getMessageQueueByIdentifier();
$defaultFlashMessageQueue->enqueue($flashMessage);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment