Skip to content

Commit bb487f0

Browse files
committed
fix: add rawPath check
1 parent 1e404ec commit bb487f0

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ run-local: stop build
1010
stop:
1111
docker kill $(CONTAINER_NAME) ; true
1212

13+
test:
14+
go test -v ./...
15+
1316
lint:
1417
go vet ./...
1518
go run honnef.co/go/tools/cmd/staticcheck@latest ./...

aws/adaptor.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ type integrationTypeChecker struct {
4444
// 'http_method' parameter has event of API Gateway REST API mode and ALB target group mode.
4545
// However, ALB target group mode has not 'resource' parameter.
4646
HTTPMethod *string `json:"httpMethod"`
47+
// Headers parameters has all API HTTP event.
48+
RawPath *string `json:"rawPath"`
4749

4850
RequestContext struct {
4951
// 'connectionID' parameter nly has API Gateway Websocket mode event.
@@ -62,7 +64,7 @@ func (t integrationTypeChecker) IntegrationType() LambdaIntegrationType {
6264
if t.RequestContext.ConnectionID != nil {
6365
return APIGatewayWebsocketIntegration
6466
}
65-
if t.Version != nil {
67+
if t.Version != nil && t.RawPath != nil {
6668
if t.RouteKey == "$default" && t.PathParameters == nil {
6769
return LambdaFunctionURLIntegration
6870
}

0 commit comments

Comments
 (0)