Skip to content

Commit 943e0c6

Browse files
committed
fix(aws-resrjson-server): fix the failing protocol test
1 parent 25da945 commit 943e0c6

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

codegen/smithy-aws-typescript-codegen/src/main/java/software/amazon/smithy/aws/typescript/codegen/AwsProtocolUtils.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -399,12 +399,6 @@ private static boolean filterMalformedRequestTests(
399399
|| testCase.getId().equals("RestJsonWithBodyExpectsApplicationJsonContentTypeNoHeaders")) {
400400
return true;
401401
}
402-
403-
// ToDo: https://github.com/aws/aws-sdk-js-v3/issues/6907
404-
if (testCase.getId().equals("RestJsonWithoutBodyEmptyInputExpectsEmptyContentType")) {
405-
return true;
406-
}
407-
408402
return false;
409403
}
410404
}

private/aws-restjson-server/src/protocols/Aws_restJson1.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2053,7 +2053,7 @@ export const deserializeMalformedContentTypeWithoutBodyEmptyInputRequest = async
20532053
);
20542054
if (contentTypeHeaderKey != null) {
20552055
const contentType = output.headers[contentTypeHeaderKey];
2056-
if (contentType !== undefined && contentType !== "application/json") {
2056+
if (contentType !== undefined) {
20572057
throw new __UnsupportedMediaTypeException();
20582058
}
20592059
}

0 commit comments

Comments
 (0)