psalm-plugin-symfony
psalm-plugin-symfony copied to clipboard
Psalm Plugin for Symfony
These keys are added to `FormView::$vars` here: https://github.com/symfony/symfony/blob/4a22bcbda96f347cafd943236bd3029a9fef9467/src/Symfony/Component/Form/Extension/Core/Type/FormType.php#L107 That's the basic `FormType` at the very top of the Form Type hierarchy, so about any `FormView` instance should have these keys...
I have a variable declared in config/services.yaml ``` parameters: login_url: '%env(string:APP_FRONTEND_DOMAIN)%' ``` I am accessing it in my controller like this: `$loginUrl = (string) ($this->getParameter('login_url') ?? "");` Everything works fine,...
After https://github.com/psalm/psalm-plugin-symfony/issues/269 was closed, I was fixing my code to comply with doctrine recommendations and noticed that the exception is not thrown if the parameter type is defined inside an...
This PR adds PHP 8.1 to GA pipeline
This PR handles ImplicitToStringCast when EnumRequirement is used in the Route requirements. New feature introduced in Symfony Routing 6.1: https://symfony.com/blog/new-in-symfony-6-1-improved-routing-requirements-and-utf-8-parameters#using-php-backedenum-as-route-requirements Current code does not pass test on PHP 8.1. Need...
When form types are created from controller like this: ```php public function __invoke() { $form = $this->createForm(SearchType::class); $form->handleRequest($request); if ($form->isSubmitted() && $form->isValid()) { $code = $form->getData(); //
With service locator anti-pattern being deprecated long ago, we can now use ``ServiceLocator`` class for tagged services. If you check compiler passes, it is only used for that anyway. Use...
Support @reqired annotation and #[Required] attribute for properties. Prevent PropertyNotSetInConstructor when ContainerAwareTrait used. for #141 and #140
In a Validator we inject the `ManagerRegistry` dependencie (do the same with the old `EntityManagerInterface` service), this cause an exception: > Uncaught Exception: RuntimeException PHP Error: ReflectionClass::__construct(): Passing null to...