File tree Expand file tree Collapse file tree 3 files changed +15
-9
lines changed Expand file tree Collapse file tree 3 files changed +15
-9
lines changed Original file line number Diff line number Diff line change 11import type { APIGatewayProxyResultV2 } from 'aws-lambda'
2- import { type Static } from '@sinclair/typebox'
2+ import type { Static } from '@sinclair/typebox'
33import { Context , ProblemDetail } from '@hello.nrfcloud.com/proto/hello'
44
55export const aProblem = (
Original file line number Diff line number Diff line change 1- import lambda from 'aws-lambda'
2- import { type MiddlewareObj } from '@middy/core'
1+ import type {
2+ APIGatewayProxyEventV2 ,
3+ APIGatewayProxyStructuredResultV2 ,
4+ } from 'aws-lambda'
5+ import type { MiddlewareObj } from '@middy/core'
36
47export const addVersionHeader = (
58 version : string ,
69) : MiddlewareObj <
7- lambda . APIGatewayProxyEventV2 ,
8- lambda . APIGatewayProxyStructuredResultV2
10+ APIGatewayProxyEventV2 ,
11+ APIGatewayProxyStructuredResultV2
912> => ( {
1013 after : async ( req ) => {
1114 if ( req . response === null ) return
Original file line number Diff line number Diff line change 1- import lambda from 'aws-lambda'
2- import { type MiddlewareObj } from '@middy/core'
1+ import type {
2+ APIGatewayProxyEventV2 ,
3+ APIGatewayProxyStructuredResultV2 ,
4+ } from 'aws-lambda'
5+ import type { MiddlewareObj } from '@middy/core'
36import { corsHeaders } from './corsHeaders.js'
47
58export const corsOPTIONS = (
69 ...allowedMethods : string [ ]
710) : MiddlewareObj <
8- lambda . APIGatewayProxyEventV2 ,
9- lambda . APIGatewayProxyStructuredResultV2
11+ APIGatewayProxyEventV2 ,
12+ APIGatewayProxyStructuredResultV2
1013> => ( {
1114 before : async ( req ) => {
1215 if ( req . event . requestContext . http . method === 'OPTIONS' ) {
You can’t perform that action at this time.
0 commit comments