소스 검색

优化取值

icssoa 5 달 전
부모
커밋
0275812c7a
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      cool/router/index.ts

+ 1 - 1
cool/router/index.ts

@@ -257,7 +257,7 @@ export class Router {
 
 	// 获取页面元数据
 	getMeta(path: string) {
-		return PAGES.find((e) => e.path.includes(path))?.meta ?? ({} as UTSJSONObject);
+		return PAGES.find((e) => path.includes(e.path))?.meta ?? ({} as UTSJSONObject);
 	}
 
 	// 执行当前页面暴露的方法