Skip to content

Commit

Permalink
Replace universal access with common interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
blakeembrey committed May 22, 2019
1 parent 2dca0de commit cee7f91
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
12 changes: 6 additions & 6 deletions package-lock.json

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

4 changes: 2 additions & 2 deletions package.json
Expand Up @@ -72,7 +72,7 @@
"lint-staged": "^8.1.7",
"prettier": "^1.17.1",
"rimraf": "^2.5.4",
"servie": "^4.0.5",
"servie": "^4.0.6",
"servie-finalhandler": "^2.0.0",
"servie-send": "^2.0.0",
"throwback": "^4.0.0",
Expand All @@ -88,6 +88,6 @@
"dependencies": {
"debug": "^4.1.1",
"path-to-regexp": "^3.0.0",
"servie-url": "^1.0.0"
"servie-url": "^1.0.1"
}
}
4 changes: 2 additions & 2 deletions src/index.ts
@@ -1,6 +1,6 @@
import debug = require("debug");
import pathToRegexp = require("path-to-regexp");
import { Request, Response } from "servie";
import { CommonRequest, CommonResponse } from "servie/dist/common";
import { getURL } from "servie-url";

const log = debug("servie-route");
Expand All @@ -15,7 +15,7 @@ export interface RequestParams {
export function create(verb?: string) {
const matches = toMatch(verb);

return function<T extends Request, U extends Response>(
return function<T extends CommonRequest, U extends CommonResponse>(
path: pathToRegexp.Path,
fn: (req: T & RequestParams, done: () => Promise<U>) => U | Promise<U>,
options?: pathToRegexp.RegExpOptions
Expand Down

0 comments on commit cee7f91

Please sign in to comment.