From 3670cbb807e0716857b4679717eda90b922139f1 Mon Sep 17 00:00:00 2001 From: Omer Karadagli Date: Mon, 17 Feb 2014 23:14:29 +0000 Subject: [PATCH] Use consistent method chaining in BlogBundle sample application - Moved semicolon to end of last chained method - Moved getManager() to next line to avoid having multiple chained methods in the same line --- book/from_flat_php_to_symfony2.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/book/from_flat_php_to_symfony2.rst b/book/from_flat_php_to_symfony2.rst index e65f75436b9..02c456d3e15 100644 --- a/book/from_flat_php_to_symfony2.rst +++ b/book/from_flat_php_to_symfony2.rst @@ -550,7 +550,8 @@ them for you. Here's the same sample application, now built in Symfony2:: { public function listAction() { - $posts = $this->get('doctrine')->getManager() + $posts = $this->get('doctrine') + ->getManager() ->createQuery('SELECT p FROM AcmeBlogBundle:Post p') ->execute(); @@ -565,8 +566,7 @@ them for you. Here's the same sample application, now built in Symfony2:: $post = $this->get('doctrine') ->getManager() ->getRepository('AcmeBlogBundle:Post') - ->find($id) - ; + ->find($id); if (!$post) { // cause the 404 page not found to be displayed