Skip to content

Commit 7686e13

Browse files
authored
Use new array syntax and make a few minor tweaks
1 parent 463f9db commit 7686e13

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

page_creation.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ to creating a page?
8686
#. *Create a controller*: The method below the route - ``numberAction()`` - is called
8787
the *controller*: this is a function where *you* build the page and ultimately
8888
return a ``Response`` object. You'll learn more about :doc:`controllers </controller>`
89-
in their own section, including how to return JSON responses;
89+
in their own section, including how to return JSON responses.
9090

9191
The Web Debug Toolbar: Debugging Dream
9292
--------------------------------------
@@ -133,9 +133,9 @@ variable so we can render that::
133133
{
134134
$number = mt_rand(0, 100);
135135

136-
return $this->render('lucky/number.html.twig', array(
137-
'number' => $number
138-
));
136+
return $this->render('lucky/number.html.twig', [
137+
'number' => $number,
138+
]);
139139
}
140140
}
141141

@@ -184,7 +184,7 @@ So what about the other directories in the project?
184184

185185
``var/``
186186
This is where automatically-created files are stored, like cache files
187-
(``var/cache/``) and logs (``var/logs/``).
187+
(``var/cache/``), logs (``var/logs/``) and (``var/sessions/``).
188188

189189
``vendor/``
190190
Third-party (i.e. "vendor") libraries live here! These are downloaded via the `Composer`_
@@ -209,11 +209,11 @@ Bundles are registered in your ``app/AppKernel.php`` file (a rare PHP file in th
209209
{
210210
public function registerBundles()
211211
{
212-
$bundles = array(
212+
$bundles = [
213213
new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
214214
new Symfony\Bundle\TwigBundle\TwigBundle(),
215215
// ...
216-
);
216+
];
217217
// ...
218218

219219
return $bundles;

0 commit comments

Comments
 (0)