Skip to content

Commit

Permalink
fixed extract() calls
Browse files Browse the repository at this point in the history
  • Loading branch information
fabpot committed Jan 9, 2012
1 parent 7e8da09 commit bd3ca8e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions book/part4.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ a little to make templates even more readable::
$path = $request->getPathInfo();
if (isset($map[$path])) {
ob_start();
extract($request->query->all());
extract($request->query->all(), EXTR_SKIP);
include sprintf(__DIR__.'/../src/pages/%s.php', $map[$path]);
$response = new Response(ob_get_clean());
} else {
Expand Down Expand Up @@ -169,7 +169,7 @@ With this knowledge in mind, let's write the new version of our framework::
$matcher = new Routing\Matcher\UrlMatcher($routes, $context);

try {
extract($matcher->match($request->getPathInfo()));
extract($matcher->match($request->getPathInfo()), EXTR_SKIP);
ob_start();
include sprintf(__DIR__.'/../src/pages/%s.php', $_route);

Expand Down

0 comments on commit bd3ca8e

Please sign in to comment.