diff --git a/cookbook/security/acl.rst b/cookbook/security/acl.rst index 39d167b8a87..d83ed37319a 100644 --- a/cookbook/security/acl.rst +++ b/cookbook/security/acl.rst @@ -105,7 +105,7 @@ Creating an ACL, and adding an ACE // ... setup $form, and bind data if ($form->isValid()) { - $entityManager = $this->get('doctrine.orm.default_entity_manager'); + $entityManager = $this->getDoctrine()->getEntityManager(); $entityManager->persist($comment); $entityManager->flush();