Skip to content

Commit 62c4efd

Browse files
authored
fix invalid case-sensitive header name comparison (#901)
1 parent b31c8a6 commit 62c4efd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

rest/rest-sqs/src/main/scala/org/elasticmq/rest/sqs/directives/AnyParamDirectives.scala

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ trait AnyParamDirectives {
2222
private def extractActionFromHeader =
2323
extractRequest.map(request =>
2424
request.headers
25-
.find(_.name() == "X-Amz-Target")
25+
.find(_.is("x-amz-target"))
2626
.flatMap(
2727
_.value() match {
2828
case actionHeaderPattern(action) => Some(action)
@@ -35,7 +35,7 @@ trait AnyParamDirectives {
3535
private def extractAwsXRayTracingHeader =
3636
extractRequest.map(
3737
_.headers
38-
.find(_.name().equalsIgnoreCase("X-Amzn-Trace-Id"))
38+
.find(_.is("x-amzn-trace-id"))
3939
.map(_.value())
4040
)
4141

0 commit comments

Comments
 (0)