From ca699b01dd515766093e7d2312d18891e1332023 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Tue, 1 Sep 2020 03:47:13 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- system/Annotation/Annotation.php | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/system/Annotation/Annotation.php b/system/Annotation/Annotation.php index ece1aecc..b52d4da5 100644 --- a/system/Annotation/Annotation.php +++ b/system/Annotation/Annotation.php @@ -87,14 +87,7 @@ class Annotation extends BaseAnnotation if (!$this->isLegitimate($events)) { continue; } - $_key = $this->getName($annotation, $events); - if (empty($events[2])) { - $this->push($_key, [$controller, $methodName]); - } else { - $handler = $this->createHandler($controller, $methodName, $events[2]); - - $this->push($_key, $handler, [request(), [$controller, $methodName]]); - } + $this->push($this->getName($annotation, $events), [$controller, $methodName]); } } }