8000 [2.3] Removed deprecated calls by wouterj · Pull Request #9353 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[2.3] Removed deprecated calls #9353

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

Merged
merged 1 commit into from
Dec 28, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Doctrine/Form/DoctrineOrmExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public function __construct(ManagerRegistry $registry)
protected function loadTypes()
{
return array(
new Type\EntityType($this->registry, PropertyAccess::getPropertyAccessor()),
new Type\EntityType($this->registry, PropertyAccess::createPropertyAccessor()),
);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Doctrine/Form/Type/DoctrineType.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ abstract class DoctrineType extends AbstractType
public function __construct(ManagerRegistry $registry, PropertyAccessorInterface $propertyAccessor = null)
{
$this->registry = $registry;
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::getPropertyAccessor();
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::createPropertyAccessor();
}

public function buildForm(FormBuilderInterface $builder, array $options)
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Propel1/Form/PropelExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class PropelExtension extends AbstractExtension
protected function loadTypes()
{
return array(
new Type\ModelType(PropertyAccess::getPropertyAccessor()),
new Type\ModelType(PropertyAccess::createPropertyAccessor()),
new Type\TranslationCollectionType(),
new Type\TranslationType()
);
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Propel1/Form/Type/ModelType.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class ModelType extends AbstractType

public function __construct(PropertyAccessorInterface $propertyAccessor = null)
{
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::getPropertyAccessor();
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::createPropertyAccessor();
}

public function buildForm(FormBuilderInterface $builder, array $options)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function testTransWithoutCaching()
{
$translator = $this->getTranslator($this->getLoader());
$translator->setLocale('fr');
$translator->setFallbackLocale(array('en', 'es', 'pt-PT', 'pt_BR'));
$translator->setFallbackLocales(array('en', 'es', 'pt-PT', 'pt_BR'));

$this->assertEquals('foo (FR)', $translator->trans('foo'));
$this->assertEquals('bar (EN)', $translator->trans('bar'));
Expand All @@ -61,7 +61,7 @@ public function testTransWithCaching()
// prime the cache
$translator = $this->getTranslator($this->getLoader(), array('cache_dir' => $this->tmpDir));
$translator->setLocale('fr');
$translator->setFallbackLocale(array('en', 'es', 'pt-PT', 'pt_BR'));
$translator->setFallbackLocales(array('en', 'es', 'pt-PT', 'pt_BR'));

$this->assertEquals('foo (FR)', $translator->trans('foo'));
$this->assertEquals('bar (EN)', $translator->trans('bar'));
Expand All @@ -75,7 +75,7 @@ public function testTransWithCaching()
$loader = $this->getMock('Symfony\Component\Translation\Loader\LoaderInterface');
$translator = $this->getTranslator($loader, array('cache_dir' => $this->tmpDir));
$translator->setLocale('fr');
$translator->setFallbackLocale(array('en', 'es', 'pt-PT', 'pt_BR'));
$translator->setFallbackLocales(array('en', 'es', 'pt-PT', 'pt_BR'));

$this->assertEquals('foo (FR)', $translator->trans('foo'));
$this->assertEquals('bar (EN)', $translator->trans('bar'));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class ObjectChoiceList extends ChoiceList
*/
public function __construct($choices, $labelPath = null, array $preferredChoices = array(), $groupPath = null, $valuePath = null, PropertyAccessorInterface $propertyAccessor = null)
{
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::getPropertyAccessor();
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::createPropertyAccessor();
$this->labelPath = null !== $labelPath ? new PropertyPath($labelPath) : null;
$this->groupPath = null !== $groupPath ? new PropertyPath($groupPath) : null;
$this->valuePath = null !== $valuePath ? new PropertyPath($valuePath) : null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class CoreExtension extends AbstractExtension
protected function loadTypes()
{
return array(
new Type\FormType(PropertyAccess::getPropertyAccessor()),
new Type\FormType(PropertyAccess::createPropertyAccessor()),
new Type\BirthdayType(),
new Type\CheckboxType(),
new Type\ChoiceType(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class FormType extends BaseType

public function __construct(PropertyAccessorInterface $propertyAccessor = null)
{
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::getPropertyAccessor();
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::createPropertyAccessor();
}

/**
Expand Down
0