diff --git a/restify/restify-tests.ts b/restify/restify-tests.ts index 329f1e8c3..3ff16da55 100644 --- a/restify/restify-tests.ts +++ b/restify/restify-tests.ts @@ -28,6 +28,8 @@ server = restify.createServer({ responseTimeFormatter : (durationInMilliseconds: number) => {} }); +server.pre(restify.pre.sanitizePath()); + server.on('someEvent', ()=>{}); diff --git a/restify/restify.d.ts b/restify/restify.d.ts index c7ee5b14a..6bcbb5412 100644 --- a/restify/restify.d.ts +++ b/restify/restify.d.ts @@ -211,4 +211,10 @@ declare module "restify" { export function fullResponse(): RequestHandler; export var defaultResponseHeaders : any; export var CORS: CORS; + + export module pre { + export function pause(): RequestHandler; + export function sanitizePath(options?: any): RequestHandler; + export function userAgentConnection(options?: any): RequestHandler; + } }