@cfworker/web 1.12.2 → 1.12.3

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.d.ts CHANGED
@@ -36,5 +36,5 @@ export declare class Router {
36
36
  all(pathname: string, ...middleware: Middleware[]): this;
37
37
  middleware: Middleware;
38
38
  compose(conditions: RouteCondition[], ...middleware: Middleware[]): this;
39
- private resolve;
39
+ resolve(ctx: Context): Route | undefined;
40
40
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cfworker/web",
3
- "version": "1.12.2",
3
+ "version": "1.12.3",
4
4
  "description": "Web framework for Cloudflare Workers and service workers, inspired by Koa and fastify",
5
5
  "keywords": [
6
6
  "middleware",
package/src/router.ts CHANGED
@@ -117,7 +117,7 @@ export class Router {
117
117
  return this;
118
118
  }
119
119
 
120
- private resolve(ctx: Context) {
120
+ public resolve(ctx: Context) {
121
121
  return this.routes.find(
122
122
  ({ conditions }) =>
123
123
  conditions.length === 0 || conditions.every(c => c(ctx))