From 2517c97f952d1e961f03c07565a3189e2026ba86 Mon Sep 17 00:00:00 2001 From: restrry Date: Mon, 27 May 2019 14:07:33 +0200 Subject: [PATCH] use full name, auth should not mutate request --- src/core/server/http/lifecycle/auth.ts | 2 +- src/core/server/http/lifecycle/on_post_auth.ts | 2 +- src/core/server/http/lifecycle/on_pre_auth.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/server/http/lifecycle/auth.ts b/src/core/server/http/lifecycle/auth.ts index 4ab1b8e39a0cb5..6310708fd040d4 100644 --- a/src/core/server/http/lifecycle/auth.ts +++ b/src/core/server/http/lifecycle/auth.ts @@ -95,7 +95,7 @@ const toolkit: AuthToolkit = { /** @public */ export type AuthenticationHandler = ( - request: Request, + request: Readonly, sessionStorage: SessionStorage, t: AuthToolkit ) => AuthResult | Promise; diff --git a/src/core/server/http/lifecycle/on_post_auth.ts b/src/core/server/http/lifecycle/on_post_auth.ts index e8d3ba33387475..92ff1c23dfdaf6 100644 --- a/src/core/server/http/lifecycle/on_post_auth.ts +++ b/src/core/server/http/lifecycle/on_post_auth.ts @@ -88,7 +88,7 @@ export interface OnPostAuthToolkit { /** @public */ export type OnPostAuthHandler = ( - req: KibanaRequest, + request: KibanaRequest, t: OnPostAuthToolkit ) => OnPostAuthResult | Promise; diff --git a/src/core/server/http/lifecycle/on_pre_auth.ts b/src/core/server/http/lifecycle/on_pre_auth.ts index 6902117ad82faf..3e2830d3ced63e 100644 --- a/src/core/server/http/lifecycle/on_pre_auth.ts +++ b/src/core/server/http/lifecycle/on_pre_auth.ts @@ -98,7 +98,7 @@ const toolkit: OnPreAuthToolkit = { /** @public */ export type OnPreAuthHandler = ( - req: KibanaRequest, + request: KibanaRequest, t: OnPreAuthToolkit ) => OnPreAuthResult | Promise;