-
Notifications
You must be signed in to change notification settings - Fork 88
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
False positive with Symfony Forms #12
Comments
FIxed in 1b66d8e |
Actually it wasn't, I completely screwed that up. @aturki can you show me what parameters (especially the first one) are you calling |
Hi @lookyman, Note the Let me know if you need extra infos ;) |
I think it's no false positive, but something ugly in the Form component: The |
I opened a ticket for this at Symfony, see symfony/symfony#35277 |
For now, the solution is to add a PHPDoc - see symfony/symfony#35277 (comment) : use Symfony\Component\Form\Form;
/** @var Form $form */
$button = $form->getClickedButton(); |
Hello all,
I get a "Call to an undefined method Symfony\Component\Form\FormInterface::getClickedButton()." error when working with Symfony Forms using the following code (within a Symfony Controller class):
$form = $this->createForm(...); $clickedButton = $form->getClickedButton();
The second line will raise the error since the
createForm
method returns a FormInterfaceThe text was updated successfully, but these errors were encountered: