Skip to content

Commit

Permalink
Revert "feature symfony#18977 [PropertyAccess] Add missing arguments …
Browse files Browse the repository at this point in the history
…to PropertyAccess::createPropertyAccessor() (chalasr)"

This reverts commit 86eb7a3, reversing
changes made to 856c9f6.
  • Loading branch information
fabpot committed Jun 21, 2016
1 parent f2ee67f commit a4ce063
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 54 deletions.
22 changes: 4 additions & 18 deletions src/Symfony/Component/PropertyAccess/PropertyAccess.php
Expand Up @@ -21,35 +21,21 @@ final class PropertyAccess
/**
* Creates a property accessor with the default configuration.
*
* @param bool $throwExceptionOnInvalidIndex
*
* @return PropertyAccessor The new property accessor
*/
public static function createPropertyAccessor($throwExceptionOnInvalidIndex = false, $magicCall = false)
public static function createPropertyAccessor()
{
return self::createPropertyAccessorBuilder($throwExceptionOnInvalidIndex, $magicCall)->getPropertyAccessor();
return self::createPropertyAccessorBuilder()->getPropertyAccessor();
}

/**
* Creates a property accessor builder.
*
* @param bool $enableExceptionOnInvalidIndex
*
* @return PropertyAccessorBuilder The new property accessor builder
*/
public static function createPropertyAccessorBuilder($enableExceptionOnInvalidIndex = false, $enableMagicCall = false)
public static function createPropertyAccessorBuilder()
{
$propertyAccessorBuilder = new PropertyAccessorBuilder();

if ($enableExceptionOnInvalidIndex) {
$propertyAccessorBuilder->enableExceptionOnInvalidIndex();
}

if ($enableMagicCall) {
$propertyAccessorBuilder->enableMagicCall();
}

return $propertyAccessorBuilder;
return new PropertyAccessorBuilder();
}

/**
Expand Down
36 changes: 0 additions & 36 deletions src/Symfony/Component/PropertyAccess/Tests/PropertyAccessTest.php

This file was deleted.

0 comments on commit a4ce063

Please sign in to comment.