From be66fb5e43d2c7d70c6f9794f20c6bacd38891c1 Mon Sep 17 00:00:00 2001 From: Adrien Castex Date: Thu, 15 Jun 2017 20:14:22 +0200 Subject: [PATCH] Removed useless exports from 'BeforeAfter.ts' file --- lib/server/webDAVServer/BeforeAfter.d.ts | 1 - lib/server/webDAVServer/BeforeAfter.js | 5 ++--- src/server/webDAVServer/BeforeAfter.ts | 7 ++++--- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/lib/server/webDAVServer/BeforeAfter.d.ts b/lib/server/webDAVServer/BeforeAfter.d.ts index 45d8bd8a..ba1b9114 100644 --- a/lib/server/webDAVServer/BeforeAfter.d.ts +++ b/lib/server/webDAVServer/BeforeAfter.d.ts @@ -1,6 +1,5 @@ import { MethodCallArgs, WebDAVRequest } from '../WebDAVRequest'; export declare function beforeRequest(manager: WebDAVRequest): void; export declare function afterRequest(manager: WebDAVRequest): void; -export declare function invokeBARequest(collection: WebDAVRequest[], base: MethodCallArgs, callback: any): void; export declare function invokeBeforeRequest(base: MethodCallArgs, callback: any): void; export declare function invokeAfterRequest(base: MethodCallArgs, callback: any): void; diff --git a/lib/server/webDAVServer/BeforeAfter.js b/lib/server/webDAVServer/BeforeAfter.js index 0f20467d..aa5565d4 100644 --- a/lib/server/webDAVServer/BeforeAfter.js +++ b/lib/server/webDAVServer/BeforeAfter.js @@ -29,12 +29,11 @@ function invokeBARequest(collection, base, callback) { } next(); } -exports.invokeBARequest = invokeBARequest; function invokeBeforeRequest(base, callback) { - this.invokeBARequest(this.beforeManagers, base, callback); + invokeBARequest(this.beforeManagers, base, callback); } exports.invokeBeforeRequest = invokeBeforeRequest; function invokeAfterRequest(base, callback) { - this.invokeBARequest(this.afterManagers, base, callback); + invokeBARequest(this.afterManagers, base, callback); } exports.invokeAfterRequest = invokeAfterRequest; diff --git a/src/server/webDAVServer/BeforeAfter.ts b/src/server/webDAVServer/BeforeAfter.ts index 4501b961..5a18621e 100644 --- a/src/server/webDAVServer/BeforeAfter.ts +++ b/src/server/webDAVServer/BeforeAfter.ts @@ -9,7 +9,7 @@ export function afterRequest(manager : WebDAVRequest) this.afterManagers.push(manager); } -export function invokeBARequest(collection : WebDAVRequest[], base : MethodCallArgs, callback) +function invokeBARequest(collection : WebDAVRequest[], base : MethodCallArgs, callback) { function callCallback() { @@ -38,11 +38,12 @@ export function invokeBARequest(collection : WebDAVRequest[], base : MethodCallA } next(); } + export function invokeBeforeRequest(base : MethodCallArgs, callback) { - this.invokeBARequest(this.beforeManagers, base, callback); + invokeBARequest(this.beforeManagers, base, callback); } export function invokeAfterRequest(base : MethodCallArgs, callback) { - this.invokeBARequest(this.afterManagers, base, callback); + invokeBARequest(this.afterManagers, base, callback); } \ No newline at end of file