From 60850b2de83396eb75ebc63cd0910e6808f0a1d7 Mon Sep 17 00:00:00 2001 From: thinkphp Date: Mon, 4 Jul 2016 11:46:14 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3Route=E7=B1=BB=E5=88=86?= =?UTF-8?q?=E7=BB=84=E7=9A=84=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/Route.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/library/think/Route.php b/library/think/Route.php index 705c7e30..686e98cf 100644 --- a/library/think/Route.php +++ b/library/think/Route.php @@ -217,8 +217,9 @@ class Route */ public static function rule($rule, $route = '', $type = '*', $option = [], $pattern = [], $group = '') { - $group = $group ?: self::$group; - $type = strtoupper($type); + $group = $group ?: self::$group; + $option = $option ?: self::$option; + $type = strtoupper($type); if (strpos($type, '|')) { foreach (explode('|', $type) as $val) { self::rule($rule, $route, $val, $option, $pattern, $group);