Skip to content

Commit

Permalink
Merge branch 'development'
Browse files Browse the repository at this point in the history
  • Loading branch information
Ardalan Amini committed Oct 6, 2018
2 parents 934c710 + ae18946 commit ef706e6
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "foxify",
"version": "0.10.1",
"version": "0.10.2",
"description": "The fast, easy to use & typescript ready web framework for Node.js",
"author": "Ardalan Amini <ardalanamini22@gmail.com> [https://github.com/ardalanamini]",
"contributors": [
Expand Down
10 changes: 9 additions & 1 deletion src/routing/Router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,15 @@ import * as Foxify from "..";

const NODE_TYPES = Layer.TYPES;

const EMPTY_HANDLE = { handlers: [], options: { schema: { response: {} } }, params: {} };
const EMPTY_HANDLE = {
handlers: [
new Encapsulation(() => {
throw new HttpException(HTTP.NOT_FOUND);
}),
],
options: { schema: { response: {} } },
params: {},
};

const pathMatchesMiddleware = (path: string, middleware: string) => {
const middlewares = middleware.replace(/(^\/|\/$)/g, "").split("/");
Expand Down

0 comments on commit ef706e6

Please sign in to comment.