Browse files

Remove duplicate code.

The conditions for persistParams() work should be self contained. Remove
this duplication.
  • Loading branch information...
1 parent 8209a29 commit 19ac39963adbb9430b465a03e06731fb2d8eff1d @markstory markstory committed Aug 2, 2013
Showing with 1 addition and 3 deletions.
  1. +1 −3 lib/Cake/Routing/Router.php
View
4 lib/Cake/Routing/Router.php
@@ -848,9 +848,7 @@ public static function url($url = null, $full = false) {
for ($i = 0, $len = count(self::$routes); $i < $len; $i++) {
$originalUrl = $url;
- if (isset(self::$routes[$i]->options['persist'], $params)) {
- $url = self::$routes[$i]->persistParams($url, $params);
- }
+ $url = self::$routes[$i]->persistParams($url, $params);
if ($match = self::$routes[$i]->match($url)) {
$output = trim($match, '/');

0 comments on commit 19ac399

Please sign in to comment.