Added auth and request storage
This commit is contained in:
@@ -11,6 +11,7 @@ import { ApplicationError, normalizePublicError } from '../../errors/index.ts';
|
||||
import { HTTP_STATUS_CODE_BAD_REQUEST, HTTP_STATUS_CODE_NO_CONTENT } from '../../constants.ts';
|
||||
import { HonoSSEStream } from '../stream/hono-sse-stream.ts';
|
||||
import { HttpRequestStream } from '../stream/http-request-stream.ts';
|
||||
import { normalizeRequestHeaders } from './request-headers.ts';
|
||||
|
||||
/** Hono context key where decoded Extended JSON bodies are stored. */
|
||||
const PARSED_BODY_KEY = 'parsedBody';
|
||||
@@ -110,6 +111,7 @@ export class HttpTransportRouter implements TransportRouter {
|
||||
|
||||
return {
|
||||
path: context.req.path,
|
||||
headers: normalizeRequestHeaders(context.req.header()),
|
||||
...(body === undefined ? {} : { body }),
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user