From 6e938d4d0bfcfaa8b734ffab637dca31bef49dfc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Fri, 30 Oct 2020 01:19:24 +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/Abstracts/BaseAnnotation.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/System/Abstracts/BaseAnnotation.php b/System/Abstracts/BaseAnnotation.php index 9841b9a0..160d0dbd 100644 --- a/System/Abstracts/BaseAnnotation.php +++ b/System/Abstracts/BaseAnnotation.php @@ -108,6 +108,9 @@ abstract class BaseAnnotation extends Component { $array = []; foreach ($annotations as $annotation) { + if (!$comment) { + continue; + } preg_match('/@(' . $annotation . ')\((.*?)\)/', $comment, $events); if (!isset($events[1])) { continue;