Skip to content

Commit

Permalink
修正Url类生成
Browse files Browse the repository at this point in the history
  • Loading branch information
liu21st committed Apr 1, 2016
1 parent b377d97 commit d5516d7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions library/think/Url.php
Original file line number Diff line number Diff line change
Expand Up @@ -226,10 +226,10 @@ public static function getRouteUrl($alias, &$vars = [])
}
$match = true;
}
if (!empty($param) && array_intersect($param, $array) == $param) {
$vars = array_diff($array, $param);
if (empty($pattern) && empty($param)) {
// 没有任何变量定义
return $url;
} elseif (!empty($match)) {
} elseif (array_intersect($param, $array) == $param) {
$vars = array_diff($array, $param);
return $url;
}
Expand Down

0 comments on commit d5516d7

Please sign in to comment.