소스 검색

Fix PropertyAccessor factory method calls

Stepan Anchugov 11 년 전
부모
커밋
7ad7232fe1
2개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      Admin/Admin.php
  2. 1 1
      Twig/Extension/SonataAdminExtension.php

+ 1 - 1
Admin/Admin.php

@@ -872,7 +872,7 @@ abstract class Admin implements AdminInterface, DomainObjectInterface
         if ($this->isChild() && $this->getParentAssociationMapping()) {
             $parent = $this->getParent()->getObject($this->request->get($this->getParent()->getIdParameter()));
 
-            $propertyAccessor = PropertyAccess::getPropertyAccessor();
+            $propertyAccessor = PropertyAccess::createPropertyAccessor();
             $propertyPath = new PropertyPath($this->getParentAssociationMapping());
 
             $object = $this->getSubject();

+ 1 - 1
Twig/Extension/SonataAdminExtension.php

@@ -227,7 +227,7 @@ class SonataAdminExtension extends \Twig_Extension
             return call_user_func(array($element, $method));
         }
 
-        return PropertyAccess::getPropertyAccessor()->getValue($element, $propertyPath);
+        return PropertyAccess::createPropertyAccessor()->getValue($element, $propertyPath);
     }
 
     /**