@kevisual/router 0.0.40 → 0.0.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/router-browser.js +1 -2
- package/dist/router.js +1 -2
- package/package.json +1 -1
- package/src/route.ts +2 -3
package/dist/router-browser.js
CHANGED
|
@@ -707,8 +707,7 @@ class QueryRouterServer extends QueryRouter {
|
|
|
707
707
|
async run(msg, ctx) {
|
|
708
708
|
const handle = this.handle;
|
|
709
709
|
if (handle) {
|
|
710
|
-
|
|
711
|
-
return handle(result);
|
|
710
|
+
return handle(msg, ctx);
|
|
712
711
|
}
|
|
713
712
|
return super.run(msg, ctx);
|
|
714
713
|
}
|
package/dist/router.js
CHANGED
|
@@ -729,8 +729,7 @@ class QueryRouterServer extends QueryRouter {
|
|
|
729
729
|
async run(msg, ctx) {
|
|
730
730
|
const handle = this.handle;
|
|
731
731
|
if (handle) {
|
|
732
|
-
|
|
733
|
-
return handle(result);
|
|
732
|
+
return handle(msg, ctx);
|
|
734
733
|
}
|
|
735
734
|
return super.run(msg, ctx);
|
|
736
735
|
}
|
package/package.json
CHANGED
package/src/route.ts
CHANGED
|
@@ -86,7 +86,7 @@ export type RouteOpts<U = {}, T = SimpleObject> = {
|
|
|
86
86
|
export type DefineRouteOpts = Omit<RouteOpts, 'idUsePath' | 'nextRoute'>;
|
|
87
87
|
const pickValue = ['path', 'key', 'id', 'description', 'type', 'middleware', 'metadata'] as const;
|
|
88
88
|
export type RouteInfo = Pick<Route, (typeof pickValue)[number]>;
|
|
89
|
-
export class Route<U = { [key: string]: any }, T extends SimpleObject =SimpleObject> {
|
|
89
|
+
export class Route<U = { [key: string]: any }, T extends SimpleObject = SimpleObject> {
|
|
90
90
|
/**
|
|
91
91
|
* 一级路径
|
|
92
92
|
*/
|
|
@@ -658,8 +658,7 @@ export class QueryRouterServer extends QueryRouter {
|
|
|
658
658
|
async run(msg: { id?: string; path?: string; key?: string; payload?: any }, ctx?: RouteContext & { [key: string]: any }) {
|
|
659
659
|
const handle = this.handle;
|
|
660
660
|
if (handle) {
|
|
661
|
-
|
|
662
|
-
return handle(result);
|
|
661
|
+
return handle(msg, ctx);
|
|
663
662
|
}
|
|
664
663
|
return super.run(msg, ctx);
|
|
665
664
|
}
|