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

Skip to content

Commit f5cc9fd

Browse files
committed
Merge branch '4.4'
* 4.4: [OptionsResolver] Add note about deprecated options
2 parents 391760c + 95cea71 commit f5cc9fd

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

components/options_resolver.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -739,6 +739,13 @@ method::
739739
somewhere, either its value is provided by the user or the option is evaluated
740740
within closures of lazy options and normalizers.
741741

742+
.. note::
743+
744+
When using an option deprecated by you in your own library, you can pass
745+
``false`` as the second argument of the
746+
:method:`Symfony\\Component\\OptionsResolver\\Options::offsetGet()` method
747+
to not trigger the deprecation warning.
748+
742749
Instead of passing the message, you may also pass a closure which returns
743750
a string (the deprecation message) or an empty string to ignore the deprecation.
744751
This closure is useful to only deprecate some of the allowed types or values of

0 commit comments

Comments
 (0)