From 56b21fc155424efeffc87898963aedaa458cb7a1 Mon Sep 17 00:00:00 2001 From: crazywhalecc Date: Sat, 10 Jun 2023 14:27:27 +0800 Subject: [PATCH] update to 3.2.2, fix ergodic annotation order --- src/ZM/Annotation/AnnotationParser.php | 2 +- src/ZM/Framework.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ZM/Annotation/AnnotationParser.php b/src/ZM/Annotation/AnnotationParser.php index c8af471b..631a890a 100644 --- a/src/ZM/Annotation/AnnotationParser.php +++ b/src/ZM/Annotation/AnnotationParser.php @@ -165,7 +165,7 @@ class_annotations: [ // 用 clone 的目的是生成个独立的对象,避免和 class 以及方法之间互相冲突 $copy = clone $vs; $copy->method = $method->getName(); - array_unshift($reflection_tree[$v]['methods_annotations'][$method->getName()], $copy); + $reflection_tree[$v]['methods_annotations'][$method->getName()][] = $copy; $annotation_list[get_class($vs)][] = $copy; } // 标记为 Ergodic 的类注解,不作为类的注解解析,而是全部当作每个方法有注解,所以直接跳过 diff --git a/src/ZM/Framework.php b/src/ZM/Framework.php index e933efef..5b25163d 100644 --- a/src/ZM/Framework.php +++ b/src/ZM/Framework.php @@ -50,7 +50,7 @@ class Framework public const VERSION_ID = 722; /** @var string 版本名称 */ - public const VERSION = '3.2.1'; + public const VERSION = '3.2.2'; /** * @var RuntimePreferences 运行时偏好(环境信息&参数)