feature #16687 [Form] Deprecated TimezoneType::getTimezones() (webmozart)
This PR was merged into the 2.8 branch.
Discussion
----------
[Form] Deprecated TimezoneType::getTimezones()
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This method is useless as of https://github.com/symfony/symfony/pull/16681. It needs to be deprecated before we can remove it since it is public.
Commits
-------
41df3fc
[Form] Deprecated TimezoneType::getTimezones()
This commit is contained in:
commit
6dacdc4ebd
@ -252,6 +252,9 @@ Form
|
|||||||
</service>
|
</service>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
* The `TimezoneType::getTimezones()` method was deprecated and will be removed
|
||||||
|
in Symfony 3.0. You should not use this method.
|
||||||
|
|
||||||
Translator
|
Translator
|
||||||
----------
|
----------
|
||||||
|
|
||||||
|
@ -312,6 +312,9 @@ UPGRADE FROM 2.x to 3.0
|
|||||||
* The `Symfony\Component\Form\Extension\Core\ChoiceList\SimpleChoiceList` class has been removed in
|
* The `Symfony\Component\Form\Extension\Core\ChoiceList\SimpleChoiceList` class has been removed in
|
||||||
favor of `Symfony\Component\Form\ChoiceList\ArrayChoiceList`.
|
favor of `Symfony\Component\Form\ChoiceList\ArrayChoiceList`.
|
||||||
|
|
||||||
|
* The `TimezoneType::getTimezones()` method was removed. You should not use
|
||||||
|
this method.
|
||||||
|
|
||||||
### FrameworkBundle
|
### FrameworkBundle
|
||||||
|
|
||||||
* The `config:debug`, `container:debug`, `router:debug`, `translation:debug`
|
* The `config:debug`, `container:debug`, `router:debug`, `translation:debug`
|
||||||
|
@ -75,9 +75,13 @@ class TimezoneType extends AbstractType
|
|||||||
* overhead.
|
* overhead.
|
||||||
*
|
*
|
||||||
* @return array The timezone choices
|
* @return array The timezone choices
|
||||||
|
*
|
||||||
|
* @deprecated Deprecated since version 2.8
|
||||||
*/
|
*/
|
||||||
public static function getTimezones()
|
public static function getTimezones()
|
||||||
{
|
{
|
||||||
|
@trigger_error('The TimezoneType::getTimezones() method is deprecated since version 2.8 and will be removed in 3.0.', E_USER_DEPRECATED);
|
||||||
|
|
||||||
if (null === static::$timezones) {
|
if (null === static::$timezones) {
|
||||||
static::$timezones = array();
|
static::$timezones = array();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user