Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Remove FQCN type hints on properties #44494

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
*/
class ProxyCacheWarmer implements CacheWarmerInterface
{
private ManagerRegistry $registry;
private $registry;

public function __construct(ManagerRegistry $registry)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Doctrine/ContainerAwareEventManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class ContainerAwareEventManager extends EventManager
private array $initialized = [];
private bool $initializedSubscribers = false;
private array $methods = [];
private ContainerInterface $container;
private $container;

/**
* @param list<string|EventSubscriber|array{string[], string|object}> $subscriberIds List of subscribers, subscriber ids, or [events, listener] tuples
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
*/
class DoctrineDataCollector extends DataCollector
{
private ManagerRegistry $registry;
private $registry;
private array $connections;
private array $managers;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
*/
class ContainerAwareLoader extends Loader
{
private ContainerInterface $container;
private $container;

public function __construct(ContainerInterface $container)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
*/
class DoctrineChoiceLoader extends AbstractChoiceLoader
{
private ObjectManager $manager;
private $manager;
private string $class;
private ?IdReader $idReader;
private ?EntityLoaderInterface $objectLoader;
private $idReader;
private $objectLoader;

/**
* Creates a new choice loader.
Expand Down
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Doctrine/Form/ChoiceList/IdReader.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
*/
class IdReader
{
private ObjectManager $om;
private ClassMetadata $classMetadata;
private $om;
private $classMetadata;
private bool $singleId;
private bool $intId;
private string $idField;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class ORMQueryBuilderLoader implements EntityLoaderInterface
*
* This property should only be accessed through queryBuilder.
*/
private QueryBuilder $queryBuilder;
private $queryBuilder;

public function __construct(QueryBuilder $queryBuilder)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Doctrine/IdGenerator/UlidGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

final class UlidGenerator extends AbstractIdGenerator
{
private ?UlidFactory $factory;
private $factory;

public function __construct(UlidFactory $factory = null)
{
Expand Down
7 changes: 2 additions & 5 deletions src/Symfony/Bridge/Doctrine/IdGenerator/UuidGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,13 @@

use Doctrine\ORM\EntityManager;
use Doctrine\ORM\Id\AbstractIdGenerator;
use Symfony\Component\Uid\Factory\NameBasedUuidFactory;
use Symfony\Component\Uid\Factory\RandomBasedUuidFactory;
use Symfony\Component\Uid\Factory\TimeBasedUuidFactory;
use Symfony\Component\Uid\Factory\UuidFactory;
use Symfony\Component\Uid\Uuid;

final class UuidGenerator extends AbstractIdGenerator
{
private UuidFactory $protoFactory;
private UuidFactory|NameBasedUuidFactory|RandomBasedUuidFactory|TimeBasedUuidFactory $factory;
private $protoFactory;
private $factory;
private ?string $entityGetter = null;

public function __construct(UuidFactory $factory = null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
*/
class DoctrineClearEntityManagerWorkerSubscriber implements EventSubscriberInterface
{
private ManagerRegistry $managerRegistry;
private $managerRegistry;

public function __construct(ManagerRegistry $managerRegistry)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
*/
class DoctrineExtractor implements PropertyListExtractorInterface, PropertyTypeExtractorInterface, PropertyAccessExtractorInterface
{
private EntityManagerInterface $entityManager;
private $entityManager;

public function __construct(EntityManagerInterface $entityManager)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
*/
class DoctrineTokenProvider implements TokenProviderInterface, TokenVerifierInterface
{
private Connection $conn;
private $conn;

public function __construct(Connection $conn)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
*/
class EntityUserProvider implements UserProviderInterface, PasswordUpgraderInterface
{
private ManagerRegistry $registry;
private $registry;
private ?string $managerName;
private string $classOrAlias;
private string $class;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
*/
class UniqueEntityValidator extends ConstraintValidator
{
private ManagerRegistry $registry;
private $registry;

public function __construct(ManagerRegistry $registry)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Doctrine/Validator/DoctrineLoader.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ final class DoctrineLoader implements LoaderInterface
{
use AutoMappingTrait;

private EntityManagerInterface $entityManager;
private $entityManager;
private ?string $classValidatorRegexp;

public function __construct(EntityManagerInterface $entityManager, string $classValidatorRegexp = null)
Expand Down
5 changes: 2 additions & 3 deletions src/Symfony/Bridge/Monolog/Command/ServerLogCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
namespace Symfony\Bridge\Monolog\Command;

use Monolog\Formatter\FormatterInterface;
use Monolog\Handler\HandlerInterface;
use Monolog\Logger;
use Symfony\Bridge\Monolog\Formatter\ConsoleFormatter;
use Symfony\Bridge\Monolog\Handler\ConsoleHandler;
Expand All @@ -33,8 +32,8 @@ class ServerLogCommand extends Command
{
private const BG_COLOR = ['black', 'blue', 'cyan', 'green', 'magenta', 'red', 'white', 'yellow'];

private ExpressionLanguage $el;
private HandlerInterface $handler;
private $el;
private $handler;

public function isEnabled(): bool
{
Expand Down
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Monolog/Formatter/ConsoleFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@ class ConsoleFormatter implements FormatterInterface
];

private array $options;
private VarCloner $cloner;
private $cloner;

/**
* @var resource|null
*/
private $outputBuffer;

private CliDumper $dumper;
private $dumper;

/**
* Available options:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
*/
class VarDumperFormatter implements FormatterInterface
{
private VarCloner $cloner;
private $cloner;

public function __construct(VarCloner $cloner = null)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Monolog/Handler/ChromePhpHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
class ChromePhpHandler extends BaseChromePhpHandler
{
private array $headers = [];
private Response $response;
private $response;

/**
* Adds the headers to the response once it's created.
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Monolog/Handler/ConsoleHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
*/
class ConsoleHandler extends AbstractProcessingHandler implements EventSubscriberInterface
{
private ?OutputInterface $output;
private $output;
private array $verbosityLevelMap = [
OutputInterface::VERBOSITY_QUIET => Logger::ERROR,
OutputInterface::VERBOSITY_NORMAL => Logger::WARNING,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class ElasticsearchLogstashHandler extends AbstractHandler

private string $endpoint;
private string $index;
private HttpClientInterface $client;
private $client;

/**
* @var \SplObjectStorage<ResponseInterface, null>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
namespace Symfony\Bridge\Monolog\Handler\FingersCrossed;

use Monolog\Handler\FingersCrossed\ActivationStrategyInterface;
use Symfony\Component\HttpFoundation\RequestStack;
use Symfony\Component\HttpKernel\Exception\HttpException;

/**
Expand All @@ -27,9 +26,9 @@ final class HttpCodeActivationStrategy implements ActivationStrategyInterface
* @param array $exclusions each exclusion must have a "code" and "urls" keys
*/
public function __construct(
private RequestStack $requestStack,
private $requestStack,
private array $exclusions,
private ActivationStrategyInterface $inner,
private $inner,
) {
foreach ($exclusions as $exclusion) {
if (!\array_key_exists('code', $exclusion)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
namespace Symfony\Bridge\Monolog\Handler\FingersCrossed;

use Monolog\Handler\FingersCrossed\ActivationStrategyInterface;
use Symfony\Component\HttpFoundation\RequestStack;
use Symfony\Component\HttpKernel\Exception\HttpException;

/**
Expand All @@ -27,9 +26,9 @@ final class NotFoundActivationStrategy implements ActivationStrategyInterface
private string $exclude;

public function __construct(
private RequestStack $requestStack,
private $requestStack,
array $excludedUrls,
private ActivationStrategyInterface $inner
private $inner
) {
$this->exclude = '{('.implode('|', $excludedUrls).')}i';
}
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Monolog/Handler/FirePHPHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
class FirePHPHandler extends BaseFirePHPHandler
{
private array $headers = [];
private Response $response;
private $response;

/**
* Adds the headers to the response once it's created.
Expand Down
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Monolog/Handler/MailerHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
*/
class MailerHandler extends AbstractProcessingHandler
{
private MailerInterface $mailer;
private \Closure|Email $messageTemplate;
private $mailer;
private $messageTemplate;

public function __construct(MailerInterface $mailer, callable|Email $messageTemplate, string|int $level = Logger::DEBUG, bool $bubble = true)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Monolog/Handler/NotifierHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
*/
class NotifierHandler extends AbstractHandler
{
private NotifierInterface $notifier;
private $notifier;

public function __construct(NotifierInterface $notifier, string|int $level = Logger::ERROR, bool $bubble = true)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Monolog/Processor/DebugProcessor.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class DebugProcessor implements DebugLoggerInterface, ResetInterface
{
private array $records = [];
private array $errorCount = [];
private ?RequestStack $requestStack;
private $requestStack;

public function __construct(RequestStack $requestStack = null)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
*/
class LazyLoadingValueHolderFactory extends BaseFactory
{
private ProxyGeneratorInterface $generator;
private $generator;

/**
* {@inheritdoc}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
*/
class RuntimeInstantiator implements InstantiatorInterface
{
private LazyLoadingValueHolderFactory $factory;
private $factory;

public function __construct()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
class ProxyDumper implements DumperInterface
{
private string $salt;
private LazyLoadingValueHolderGenerator $proxyGenerator;
private BaseGeneratorStrategy $classGenerator;
private $proxyGenerator;
private $classGenerator;

public function __construct(string $salt = '')
{
Expand Down
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Twig/AppVariable.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
*/
class AppVariable
{
private TokenStorageInterface $tokenStorage;
private RequestStack $requestStack;
private $tokenStorage;
private $requestStack;
private string $environment;
private bool $debug;

Expand Down
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Twig/Command/DebugCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
#[AsCommand(name: 'debug:twig', description: 'Show a list of twig functions, filters, globals and tests')]
class DebugCommand extends Command
{
private Environment $twig;
private $twig;
private ?string $projectDir;
private array $bundlesMetadata;
private ?string $twigDefaultPath;
Expand All @@ -46,7 +46,7 @@ class DebugCommand extends Command
*/
private array $filesystemLoaders;

private ?FileLinkFormatter $fileLinkFormatter;
private $fileLinkFormatter;

public function __construct(Environment $twig, string $projectDir = null, array $bundlesMetadata = [], string $twigDefaultPath = null, FileLinkFormatter $fileLinkFormatter = null)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Twig/Command/LintCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
#[AsCommand(name: 'lint:twig', description: 'Lint a Twig template and outputs encountered errors')]
class LintCommand extends Command
{
private Environment $twig;
private $twig;
private string $format;

public function __construct(Environment $twig)
Expand Down
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Twig/DataCollector/TwigDataCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
*/
class TwigDataCollector extends DataCollector implements LateDataCollectorInterface
{
private Profile $profile;
private ?Environment $twig;
private $profile;
private $twig;
private array $computed;

public function __construct(Profile $profile, Environment $twig = null)
Expand Down
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Twig/ErrorRenderer/TwigErrorRenderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
*/
class TwigErrorRenderer implements ErrorRendererInterface
{
private Environment $twig;
private HtmlErrorRenderer $fallbackErrorRenderer;
private $twig;
private $fallbackErrorRenderer;
private \Closure|bool $debug;

/**
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Twig/Extension/AssetExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
*/
final class AssetExtension extends AbstractExtension
{
private Packages $packages;
private $packages;

public function __construct(Packages $packages)
{
Expand Down
Loading