From 22e8df0daa26b5b8fb5952f290f01a40e833361f Mon Sep 17 00:00:00 2001 From: Lauri Date: Tue, 19 Oct 2021 16:10:26 +0300 Subject: [PATCH] Fix opening brace style The opening brace should go on the same line like it is for another function (is_leap_year) in the same page. --- create_framework/templating.rst | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/create_framework/templating.rst b/create_framework/templating.rst index 4ae746e1c91..45fc99e0452 100644 --- a/create_framework/templating.rst +++ b/create_framework/templating.rst @@ -38,8 +38,7 @@ that renders a template when there is no specific logic. To keep the same template as before, request attributes are extracted before the template is rendered:: - function render_template($request) - { + function render_template($request) { extract($request->attributes->all(), EXTR_SKIP); ob_start(); include sprintf(__DIR__.'/../src/pages/%s.php', $_route); @@ -106,8 +105,7 @@ Here is the updated and improved version of our framework:: use Symfony\Component\HttpFoundation\Response; use Symfony\Component\Routing; - function render_template($request) - { + function render_template($request) { extract($request->attributes->all(), EXTR_SKIP); ob_start(); include sprintf(__DIR__.'/../src/pages/%s.php', $_route);