Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
minor fix
  • Loading branch information
HeahDude authored Jul 25, 2017
commit 22314eb49e412210269b320c4312b3946a44b791
2 changes: 1 addition & 1 deletion form/multiple_buttons.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ querying if the "Save and add" button was clicked::
Or you can get the button's name by using the
:method:`Symfony\\Component\\Form\\Form::getClickedButton` method of the form::

if ('saveAndAdd' === $form->getClickedButton()->getName()) {
if ($form->getClickedButton() && 'saveAndAdd' === $form->getClickedButton()->getName()) {
// ...
}

Expand Down